Indigo

Distribution

The following items are included:

Depending on the OS and architecture, proper binaries are loaded automatically.

Cano Class Constructors

Cano (String path);

Receives the path to Win, Linux, and Mac directories containing binary modules (see distribution section above for details). E.g., if the libraries are stored in lib/Win/, lib/Linux, and lib/Mac directories, call new Cano(“lib”). You can specify absolute paths as well.

Cano ();

Same as Cano(“lib”).

Instances are independent and are safe to be used in parallel.

Cano Class Public Methods

String getVersion ()

Returns the version of the library.

String getCanonicalSmiles (String molecule, String options)

Computes the canonical SMILES of the given molecule with given options. The molecule is either SMILES or MDL (Symyx) Molfile (the format is detected automatically). The options string can contain space-separated words AROMATICITY, TETRAHEDRAL, and CISTRANS, each preceded with plus or minus sign. You can pass null in place of options string. The default option is all options on: +AROMATICITY, +TETRAHEDRAL, and +CISTRANS.

String getCanonicalSmiles (String molecule)

The same as the above, with no options.

String getLayeredCode (String molecule, String options)

Computes the canonical layered code of the given molecule. The molecule and options are the same as for getCanonicalSmiles() call.

String getLayeredCode (String molecule)

The same as the above, with no options.

Example

public static void main (String[] args) throws IOException
{
   try
   {
      Cano cano = new Cano();

      System.out.println(cano.getVersion());
      System.out.println(cano.getCanonicalSmiles("C1C=CC=CC=1", null));
      System.out.println(cano.getCanonicalSmiles("NC1C=C(Br)C=CC=1", ""));
      System.out.println(cano.getCanonicalSmiles("NC1C=C(Br)C=CC=1", "-AROMATICITY"));
      System.out.println(cano.getCanonicalSmiles("N1(C(SCC1C(=O)N[C@@H](CCO)C)C1CC2CCC1C2)C(CN(CC)C)=O |a:8|"));
      System.out.println(cano.getLayeredCode("NC1C=C(Br)C=CC=1"));
      System.out.println(cano.getLayeredCode("C[C@@H]1CC(C(=O)N1)1N2CC(C)3CN1CC(C)(C2)C3=O", "-CISTRANS")); 
   }
   catch (Exception e)
   {
      System.out.println(e.getMessage());
   }
}