Class InvPair

java.lang.Object
org.openscience.cdk.smiles.InvPair
All Implemented Interfaces:
Serializable

public class InvPair extends Object implements Serializable
This is used to hold the invariance numbers for the canonical labeling of IAtomContainers.
See Also:
Source code:
main
Belongs to CDK module:
standard
  • Field Details

  • Constructor Details

    • InvPair

      public InvPair()
    • InvPair

      public InvPair(long current, IAtom atom)
  • Method Details

    • getLast

      public long getLast()
    • setCurr

      public void setCurr(long newCurr)
      Set the value of the seed. Note that use of this method implies that a new prime number is desired. If so, make sure to call setPrime() to ensure that a new prime number is obtained using the new seed. Todo make the following robust!
      See Also:
    • getCurr

      public long getCurr()
      Get the current seed.
      Returns:
      The seed
      See Also:
    • equals

      public boolean equals(Object object)
      Check whether this instance equals another instance.
      Overrides:
      equals in class Object
      Parameters:
      object - An instance of InvPair
      Returns:
      true if they are equal, false otherwise
    • hashCode

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

      public void setLast(long newLast)
    • setAtom

      public void setAtom(IAtom newAtom)
    • getAtom

      public IAtom getAtom()
    • commit

      public void commit()
    • toString

      public String toString()
      String representation.
      Overrides:
      toString in class Object
      Returns:
      The string representation of the class.
    • getPrime

      public int getPrime()
      Get the current prime number.
      Returns:
      The current prime number
      See Also:
    • setPrime

      public void setPrime()
      Sets the prime number based on the current seed. Note that if you change the seed via setCurr(long), you should make sure to call this method so that a new prime number is available via getPrime()
      See Also: