Class InChINumbersTools

java.lang.Object
org.openscience.cdk.graph.invariant.InChINumbersTools

public class InChINumbersTools extends Object
Tool for calculating atom numbers using the InChI algorithm.
Source code:
main
Belongs to CDK module:
inchi
  • Constructor Details

    • InChINumbersTools

      public InChINumbersTools()
  • Method Details

    • getNumbers

      public static long[] getNumbers(IAtomContainer atomContainer) throws CDKException
      Makes an array containing the InChI atom numbers of the non-hydrogen atoms in the atomContainer. It returns zero for all hydrogens.
      Parameters:
      atomContainer - The IAtomContainer to analyze.
      Returns:
      The number from 1 to the number of heavy atoms.
      Throws:
      CDKException - When the InChI could not be generated
    • parseAuxInfo

      public static void parseAuxInfo(String aux, long[] numbers)
      Parse the atom numbering from the auxinfo.
      Parameters:
      aux - InChI AuxInfo
      numbers - the atom numbers
    • getUSmilesNumbers

      public static long[] getUSmilesNumbers(IAtomContainer container) throws CDKException
      Obtain the InChI numbers for the input container to be used to order atoms in Universal SMILES [O'Boyle, Noel. Journal of Cheminformatics. 2012. 4]. The numbers are obtained using the fixedH and RecMet options of the InChI. All non-bridged hydrogens are labelled as 0.
      Parameters:
      container - the structure to obtain the numbers of
      Returns:
      the atom numbers
      Throws:
      CDKException