Class ReferenceTreeObject

    • Method Detail

      • getDistanceFromRoot

        public int getDistanceFromRoot()
        Returns:
        the number of steps in a referral chain from the root object
      • getLeakRelevance

        public double getLeakRelevance()
        Returns:
        the relevance of this object for memory leak detection
      • getItems

        public Set<IItem> getItems()
        This method is used when it is necessary to get information about all objects this object keeps alive in the ReferenceTreeModel. E.g. the Mission Control GUI uses this when a user selects a row in the tree to show everything below it as well in the properties view.
        Returns:
        a set representing all IItem objects this object keeps alive, including itself
      • getRootDescription

        public String getRootDescription()
        Returns:
        the GC root description
      • getArray

        public IMCOldObjectArray getArray()
        Returns:
        if this object is an array, gets information representing that array, null otherwise
      • getField

        public IMCOldObjectField getField()
        Returns:
        if this object is a field, gets information representing that field, null otherwise
      • getObjectsKeptAliveCount

        public int getObjectsKeptAliveCount()
        Returns:
        the number of objects this object keeps alive
      • getParent

        public ReferenceTreeObject getParent()
        This method returns an object that is keeping this object alive.
        Returns:
        the object linking to this object from the direction of the gc root
      • getTimestamp

        public IQuantity getTimestamp()
        Returns:
        the timestamp this object was allocated
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • setParent

        public void setParent​(ReferenceTreeObject parent)
        Parameters:
        parent - the parent of this object
      • getOldObjectSamples

        public Map<IQuantity,​ReferenceTreeObject> getOldObjectSamples()
        Returns:
        Map containing allocation time and its oldObjectReference object
      • updateOldObjectSamples

        public void updateOldObjectSamples​(ReferenceTreeObject oldobjectrefnode)
        This method updates the Root object's Map with allocationTime and its oldObjectReference object (leaves).
        Parameters:
        oldobjectrefnode - oldObjectReference leaf node
      • toString

        public String toString​(int displayFormatting)
        Returns a string representation of this object.
        Parameters:
        displayFormatting - an int describing how this object is to be represented, using bitwise masking of constants defined in ReferenceTreeObject
        Returns:
        a human readable string representation of this object