Class NodePath


  • public class NodePath
    extends java.lang.Object
    Store a path in the project for selected or expanded nodes.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected int entry
      The path entry of the root node (stored as index to distinguish between paths added twice).
      protected java.lang.String[] path
      The path items to navigate to the node.
    • Constructor Summary

      Constructors 
      Constructor Description
      NodePath()
      Create a node path.
      NodePath​(int entry, java.lang.String[] path)
      Create a node path.
    • Field Detail

      • entry

        protected int entry
        The path entry of the root node (stored as index to distinguish between paths added twice).
      • path

        protected java.lang.String[] path
        The path items to navigate to the node.
    • Constructor Detail

      • NodePath

        public NodePath()
        Create a node path.
      • NodePath

        public NodePath​(int entry,
                        java.lang.String[] path)
        Create a node path.
    • Method Detail

      • getEntry

        public int getEntry()
        Get the entry index.
      • setEntry

        public void setEntry​(int entry)
        Set the entry index.
      • getPath

        public java.lang.String[] getPath()
        Get the path.
      • setPath

        public void setPath​(java.lang.String[] path)
        Set the path.
      • hashCode

        public int hashCode()
        Get the hash code.
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Test for equality.
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Get a string representation.
        Overrides:
        toString in class java.lang.Object
      • createNodePath

        public static NodePath createNodePath​(ISwingTreeNode node)
        Create a node path for a given node.