Interface Group

All Known Subinterfaces:
ProgramFragment, ProgramModule

public interface Group
The interface for groupings of code units that may have attributes such as names and comments.
  • Method Details

    • getComment

      String getComment()
      Obtains the comment that has been associated with this fragment or module.
      Returns:
      may be null.
    • setComment

      void setComment(String comment)
      Sets the comment to associate with this fragment.
      Parameters:
      comment - the comment.
    • getName

      String getName()
      Obtains the name that has been associated with this fragment. A fragment will always have a name and it will be unique within the set of all fragment and module names.
    • setName

      void setName(String name) throws DuplicateNameException
      Sets the name of this fragment.
      Parameters:
      name - the string to use for the fragment's name.
      Throws:
      DuplicateNameException - thrown if the name being set is already in use by another fragment or a module.
    • contains

      boolean contains(CodeUnit codeUnit)
      Returns whether this fragment contains the given code unit.
      Parameters:
      codeUnit - the code unit being tested.
      Returns:
      true if the code unit is in the fragment, false otherwise.
    • getNumParents

      int getNumParents()
      Obtains the number of parent's of this fragment. If a fragment is in a module then the module is a parent of the fragment and the fragment is a child of the module. A fragment must have at least one parent and it may have multiple parents.
      Returns:
      the number of parents of this fragment.
    • getParents

      ProgramModule[] getParents()
      Returns a list of the modules which are parents for this group.
    • getParentNames

      String[] getParentNames()
      Returns the names of the modules which are parents to this fragment.
    • getTreeName

      String getTreeName()
      Returns the name of the tree that this group belongs to.
    • isDeleted

      boolean isDeleted()
      Returns true if this group has been deleted from the program
      Returns:
      true if this group has been deleted from the program
    • getMinAddress

      Address getMinAddress()
    • getMaxAddress

      Address getMaxAddress()
    • getGroupPath

      default GroupPath getGroupPath()
      Returns one of many possible GroupPaths for this group. Since Fragments can belong in more than one module, there can be multiple legitimate group paths for a group. This method arbitrarily returns one valid group path.
      Returns:
      one of several possible group paths for this group