Class PatternBlock

java.lang.Object
ghidra.app.plugin.processors.sleigh.pattern.PatternBlock

public class PatternBlock extends Object
A mask/value pair viewed as two bitstreams
  • Field Details

  • Constructor Details

    • PatternBlock

      public PatternBlock(int off, int msk, int val)
    • PatternBlock

      public PatternBlock(boolean tf)
    • PatternBlock

      public PatternBlock(PatternBlock a, PatternBlock b)
    • PatternBlock

      public PatternBlock(ArrayList<?> list)
  • Method Details

    • getMaskVector

      public int[] getMaskVector()
    • getValueVector

      public int[] getValueVector()
    • clone

      public Object clone()
      Overrides:
      clone in class Object
    • andBlock

      public PatternBlock andBlock(PatternBlock b)
    • specializes

      public boolean specializes(PatternBlock op2)
    • identical

      public boolean identical(PatternBlock op2)
    • shift

      public void shift(int sa)
    • getLength

      public int getLength()
    • getMask

      public int getMask(int startbit, int size)
    • getValue

      public int getValue(int startbit, int size)
    • alwaysTrue

      public boolean alwaysTrue()
    • alwaysFalse

      public boolean alwaysFalse()
    • isInstructionMatch

      public boolean isInstructionMatch(ParserWalker walker)
    • isContextMatch

      public boolean isContextMatch(ParserWalker walker)
    • decode

      public void decode(Decoder decoder) throws DecoderException
      Throws:
      DecoderException
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getOffset

      public int getOffset()
    • getNonZeroLength

      public int getNonZeroLength()
    • getWholeBytes

      public byte[] getWholeBytes()
      Extract those portions of the pattern which constitute fully-specified bytes
      Returns:
      an array of bytes