Class Orbit

    • Constructor Detail

      • Orbit

        public Orbit​(String label,
                     int height)
        Parameters:
        label -
        height -
    • Method Detail

      • sort

        public void sort()
        Sorts the atom indices in this orbit.
      • getHeight

        public int getHeight()
        Gets the height of the signature label.
        Returns:
        the height of the signature of this orbit
      • getAtomIndices

        public List<Integer> getAtomIndices()
        Gets all the atom indices as a list.
        Returns:
        the atom indices
      • addAtom

        public void addAtom​(int atomIndex)
        Adds an atom index to the orbit.
        Parameters:
        atomIndex - the atom index
      • hasLabel

        public boolean hasLabel​(String otherLabel)
        Checks to see if the orbit has this string as a label.
        Parameters:
        otherLabel - the label to compare with
        Returns:
        true if it has this label
      • isEmpty

        public boolean isEmpty()
        Checks to see if the orbit is empty.
        Returns:
        true if there are no atom indices in the orbit
      • getFirstAtom

        public int getFirstAtom()
        Gets the first atom index of the orbit.
        Returns:
        the first atom index
      • remove

        public void remove​(int atomIndex)
        Removes an atom index from the orbit.
        Parameters:
        atomIndex - the atom index to remove
      • getLabel

        public String getLabel()
        Gets the label of the orbit.
        Returns:
        the orbit's string label
      • contains

        public boolean contains​(int atomIndex)
        Checks to see if the orbit contains this atom index.
        Parameters:
        atomIndex - the atom index to look for
        Returns:
        true if the orbit contains this atom index