Class Annotation

java.lang.Object
ghidra.app.util.viewer.field.Annotation

public class Annotation extends Object
  • Field Details

  • Constructor Details

    • Annotation

      public Annotation(String annotationText, AttributedString prototypeString, Program program)
      Constructor Note: This constructor assumes that the string starts with "{
      @
      " and ends with '}'
      Parameters:
      annotationText - The complete annotation text.
      prototypeString - An AttributedString that provides the attributes for the display text this Annotation can create
      program - the program
  • Method Details

    • getAnnotatedStringHandlers

      public static List<AnnotatedStringHandler> getAnnotatedStringHandlers()
    • getDisplayString

      public AttributedString getDisplayString()
    • handleMouseClick

      public boolean handleMouseClick(Navigatable sourceNavigatable, ServiceProvider serviceProvider)
      Called when a mouse click occurs on a FieldElement containing this Annotation.
      Parameters:
      sourceNavigatable - The source navigatable associated with the mouse click.
      serviceProvider - The service provider to be used when creating AnnotatedStringHandler instances.
      Returns:
      true if the handler desires to handle the mouse click.
    • getAnnotationText

      public String getAnnotationText()
    • toString

      public String toString()
      Overrides:
      toString in class Object