Class CodeBlockVertex

java.lang.Object
ghidra.program.model.block.graph.CodeBlockVertex
All Implemented Interfaces:
Comparable<CodeBlockVertex>

public class CodeBlockVertex extends Object implements Comparable<CodeBlockVertex>
A class for representing a code block within a graph.
  • Constructor Details

    • CodeBlockVertex

      public CodeBlockVertex(CodeBlock codeBlock)
      Constructor.
      Parameters:
      codeBlock - the code block for this vertex
    • CodeBlockVertex

      public CodeBlockVertex(String name)
      A constructor that allows for the creation of dummy nodes. This is useful in graphs where multiple entry or exit points need to be parented by a single vertex.
      Parameters:
      name - the name of this vertex
  • Method Details

    • getCodeBlock

      public CodeBlock getCodeBlock()
    • getName

      public String getName()
    • isDummy

      public boolean isDummy()
      Returns true if this vertex is not backed by a code block.
      Returns:
      true if this vertex is not backed by a code block.
    • toString

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

      public int compareTo(CodeBlockVertex o)
      Specified by:
      compareTo in interface Comparable<CodeBlockVertex>
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object