Package ghidra.app.plugin.processors.generic

# Class ConstantTemplate

java.lang.Object
ghidra.app.plugin.processors.generic.ConstantTemplate

All Implemented Interfaces:
  `Serializable`

public class ConstantTemplate extends Object implements Serializable

See Also:
  - Serialized Form

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `HANDLE`
  `static final int`
  `JUMP_CODESPACE`
  `static final int`
  `JUMP_NEXT`
  `static final int`
  `JUMP_START`
  `static final int`
  `REAL`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ConstantTemplate(int t)`
  `ConstantTemplate(long val)`
  `ConstantTemplate(Operand o, int sel1)`
  Constructor ConstantTemplate.
  `ConstantTemplate(Operand o, int sel1, int sel2)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `equals(Object o)`
  `int`
  `hashCode()`
  `Operand`
  `operand()`
  `long`
  `resolve(Position position, int off)`
  Method resolve.
  `long`
  `resolve(HashMap<Object,Handle> handles, Position position, int off)`
  `int`
  `select1()`
  `int`
  `select2()`
  `int`
  `type()`

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### REAL

    public static final int REAL
    See Also:
      - Constant Field Values

  - ### HANDLE

    public static final int HANDLE
    See Also:
      - Constant Field Values

  - ### JUMP_START

    public static final int JUMP_START
    See Also:
      - Constant Field Values

  - ### JUMP_NEXT

    public static final int JUMP_NEXT
    See Also:
      - Constant Field Values

  - ### JUMP_CODESPACE

    public static final int JUMP_CODESPACE
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### ConstantTemplate

    public ConstantTemplate(long val)

  - ### ConstantTemplate

    public ConstantTemplate(int t)

  - ### ConstantTemplate

    public ConstantTemplate(Operand o, int sel1, int sel2)

  - ### ConstantTemplate

    public ConstantTemplate(Operand o, int sel1) throws SledException
    Constructor ConstantTemplate.
    Parameters:
      `o` - the operand
      `sel1` - the first selection
    Throws:
      `SledException`

- ## Method Details

  - ### type

    public int type()

  - ### select1

    public int select1()

  - ### select2

    public int select2()

  - ### resolve

    public long resolve(Position position, int off) throws Exception
    Method resolve.
    Parameters:
      `position` - the position of the constant to resolve
      `off` - the offset of the constant
    Returns:
      long
    Throws:
      `Exception`

  - ### resolve

    public long resolve(HashMap<Object,Handle> handles, Position position, int off) throws Exception
    Parameters:
      `handles` - optional map of handles to be used for resolving
    Returns:
      long
    Throws:
      `Exception`
    See Also:
      - `resolve(Position, int)`

  - ### operand

    public Operand operand()

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `Object`

  - ### equals

    public boolean equals(Object o)
    Overrides:
      `equals` in class `Object`