Package ghidra.util.state
Class VarnodeOperation
- java.lang.Object
-
- ghidra.program.model.pcode.Varnode
-
- ghidra.util.state.VarnodeOperation
-
public class VarnodeOperation extends Varnode
-
-
Constructor Summary
Constructors Constructor Description VarnodeOperation(PcodeOp pcodeOp, Varnode[] inputValues)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)Varnode[]getInputValues()PcodeOpgetPCodeOp()inthashCode()booleanisAddress()booleanisAddrTied()booleanisConstant()booleanisFree()booleanisInput()booleanisPersistent()booleanisRegister()booleanisSimplified()booleanisUnaffected()booleanisUnique()voidsetSimplified(boolean simplified)java.lang.StringtoString()java.lang.StringtoString(Language language)Convert this varnode to an alternate String representation based on a specified language.voidtrim()Trim a varnode in a constant space to the correct starting offset.-
Methods inherited from class ghidra.program.model.pcode.Varnode
buildXML, contains, getAddress, getDef, getDescendants, getHigh, getLoneDescend, getMergeGroup, getOffset, getPCAddress, getSize, getSpace, getWordOffset, intersects, intersects, isHash, readXML
-
-
-
-
Method Detail
-
isSimplified
public boolean isSimplified()
-
setSimplified
public void setSimplified(boolean simplified)
-
getPCodeOp
public PcodeOp getPCodeOp()
-
getInputValues
public Varnode[] getInputValues()
-
toString
public java.lang.String toString(Language language)
Description copied from class:VarnodeConvert this varnode to an alternate String representation based on a specified language.
-
isAddress
public boolean isAddress()
- Overrides:
isAddressin classVarnode- Returns:
- true if this varnode exists in a Memory space (vs. register etc...).
Keep in mind this varnode may also correspond to a defined register
if true is returned and
Varnode.isRegister()return false. Memory-based registers may be indirectly addressed which leads to the distinction with registers within the register space.
-
isAddrTied
public boolean isAddrTied()
- Overrides:
isAddrTiedin classVarnode- Returns:
- is mapped to an address
-
isConstant
public boolean isConstant()
- Overrides:
isConstantin classVarnode- Returns:
- true if this varnode is just a constant number
-
isInput
public boolean isInput()
-
isPersistent
public boolean isPersistent()
- Overrides:
isPersistentin classVarnode- Returns:
- is persistent
-
isRegister
public boolean isRegister()
- Overrides:
isRegisterin classVarnode- Returns:
- true if this varnode exists in a Register type space. If false is returned, keep in mind this varnode may still correspond to a defined register within a memory space. Memory-based registers may be indirectly addressed which leads to the distinction with registers within the register space.
-
isUnaffected
public boolean isUnaffected()
- Overrides:
isUnaffectedin classVarnode
-
isUnique
public boolean isUnique()
-
trim
public void trim()
Description copied from class:VarnodeTrim a varnode in a constant space to the correct starting offset. Constant handles may contain constants of indeterminate size. This is where the size gets fixed, i.e. we mask off the constant to its proper size. A varnode that is ends up in pcode should call this method to ensure that varnodes always contains raw data. On the other hand, varnodes in handles are allowed to have offsets that violate size restrictions.
-
-