Class XReferenceUtil


  • @Deprecated
    public class XReferenceUtil
    extends java.lang.Object
    Deprecated.
    deprecated for 10.1; removal for 10.3 or later
    A utility class to handle the generation of direct and offcut cross-reference (xref) lists on code units and stack variables.
    • Constructor Detail

      • XReferenceUtil

        public XReferenceUtil()
        Deprecated.
    • Method Detail

      • getXRefList

        public static final Address[] getXRefList​(CodeUnit cu)
        Deprecated.
        Returns an array containing all direct xref addresses to the specified code unit.
        Parameters:
        cu - the code unit to generate the xrefs
        Returns:
        array of all xrefs to the code unit
      • getXRefList

        public static final Address[] getXRefList​(CodeUnit cu,
                                                  int maxNumber)
        Deprecated.
        Returns an array containing the first maxNumber direct xref addresses to the specified code unit.
        Parameters:
        cu - the code unit to generate the xrefs
        maxNumber - max number of xrefs to get, or -1 to get all references
        Returns:
        array first maxNumber xrefs to the code unit
      • getXReferences

        public static final Reference[] getXReferences​(CodeUnit cu,
                                                       int maxNumber)
        Deprecated.
        Returns an array containing the first maxNumber direct xref references to the specified code unit.
        Parameters:
        cu - the code unit to generate the xrefs
        maxNumber - max number of xrefs to get, or -1 to get all references
        Returns:
        array first maxNumber xrefs to the code unit
      • getOffcutXRefList

        public static final Address[] getOffcutXRefList​(CodeUnit cu)
        Deprecated.
        Returns an array containing all offcut xref addresses to the specified code unit.
        Parameters:
        cu - the code unit to generate the offcut xrefs
        Returns:
        array of all offcut xrefs to the code unit
      • getOffcutXRefList

        public static final Address[] getOffcutXRefList​(CodeUnit cu,
                                                        int maxXRefs)
        Deprecated.
        Returns an array containing all offcut xref addresses to the specified code unit.
        Parameters:
        cu - the code unit to generate the offcut xrefs
        maxXRefs - max number of offcut xrefs to get, or -1 to get all offcut references
        Returns:
        array of all offcut xrefs to the code unit
      • getOffcutXReferences

        public static final Reference[] getOffcutXReferences​(CodeUnit cu,
                                                             int maxXRefs)
        Deprecated.
        Returns an array containing all offcut xref references to the specified code unit
        Parameters:
        cu - the code unit to generate the offcut xrefs
        maxXRefs - max number of offcut xrefs to get, or -1 to get all offcut references
        Returns:
        array of all offcut xrefs to the code unit
      • getOffcutXRefCount

        public static int getOffcutXRefCount​(CodeUnit cu)
        Deprecated.
        Returns the count of all offcut xref addresses to the specified code unit
        Parameters:
        cu - the code unit to generate the offcut xrefs
        Returns:
        count of all offcut xrefs to the code unit
      • getVariableRefs

        public static void getVariableRefs​(Variable var,
                                           java.util.List<Reference> xrefs,
                                           java.util.List<Reference> offcuts)
        Deprecated.
        Populates the provided lists with the direct and offcut xrefs to the specified variable
        Parameters:
        var - variable to get references
        xrefs - list to put direct references in
        offcuts - list to put offcut references in
      • getVariableRefs

        public static java.util.Set<Reference> getVariableRefs​(Variable var)
        Deprecated.
        Returns the direct and offcut xrefs to the specified variable
        Parameters:
        var - variable to get references
        Returns:
        the set of references
      • showAllXrefs

        public static void showAllXrefs​(Navigatable navigatable,
                                        ServiceProvider serviceProvider,
                                        TableService service,
                                        ProgramLocation location,
                                        java.util.Set<Reference> xrefs)
        Deprecated.
        Shows all xrefs to the given location in a new table. These xrefs are retrieved from the given supplier. Thus, it is up to the client to determine which xrefs to show.
        Parameters:
        navigatable - the navigatable used for navigation from the table
        serviceProvider - the service provider needed to wire navigation
        service - the service needed to show the table
        location - the location for which to find references
        xrefs - the xrefs to show
      • getAllXrefs

        public static java.util.Set<Reference> getAllXrefs​(ProgramLocation location)
        Deprecated.
        Returns all xrefs to the given location. If in data, then xrefs to the specific data component will be returned. Otherwise, the code unit containing the address of the given location will be used as the source of the xrefs.
        Parameters:
        location - the location for which to get xrefs
        Returns:
        the xrefs