Package ghidra.app.decompiler.signature

# Class DebugSignature

java.lang.Object
ghidra.app.decompiler.signature.DebugSignature

Direct Known Subclasses:
  `BlockSignature`, `CopySignature`, `VarnodeSignature`

public abstract class DebugSignature extends Object
A feature extracted from a function, with an additional description of what information is incorporated into the feature. The feature may incorporate data-flow and/or control-flow information from the function. Internally, the feature is a 32-bit hash of this information, but derived classes from this abstract class include more detailed information about how the hash was formed.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `int`
  `hash`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DebugSignature()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `abstract void`
  `decode(Decoder decoder)`
  Decode the feature from a stream.
  `static ArrayList<DebugSignature>`
  `decodeSignatures(Decoder decoder, Function func)`
  Decode an array of features from the stream.
  `abstract void`
  `printRaw(Language language, StringBuffer buf)`
  Write a brief description of this feature to the given StringBuffer.

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

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

- ## Field Details

  - ### hash

    public int hash

- ## Constructor Details

  - ### DebugSignature

    public DebugSignature()

- ## Method Details

  - ### decode

    public abstract void decode(Decoder decoder) throws DecoderException
    Decode the feature from a stream.
    Parameters:
      `decoder` - is the stream decoder
    Throws:
      `DecoderException` - for problems reading the stream

  - ### printRaw

    public abstract void printRaw(Language language, StringBuffer buf)
    Write a brief description of this feature to the given StringBuffer.
    Parameters:
      `language` - is the underlying language of the function
      `buf` - is the given StringBuffer

  - ### decodeSignatures

    public static ArrayList<DebugSignature> decodeSignatures(Decoder decoder, Function func) throws DecoderException
    Decode an array of features from the stream. Collectively, the features make up a "feature vector" for a specific function. Each feature is returned as a separate descriptive object.
    Parameters:
      `decoder` - is the stream decoder
      `func` - is the specific function whose feature vector is being decoded
    Returns:
      the array of feature objects
    Throws:
      `DecoderException` - for problems reading from the stream