Class SmiFlavor


public final class SmiFlavor extends Object
Flags for customising SMILES generation.
  • Field Details

    • Canonical

      public static final int Canonical
      Output SMILES in a canonical order. The order is not guaranteed to be equivalent between releases.
      See Also:
    • InChILabelling

      public static final int InChILabelling
      Output SMILES in a canonical order using the InChI labelling algorithm.
      See Also:
    • AtomAtomMap

      public static final int AtomAtomMap
      Output atom-atom mapping for reactions and atom classes for molecules. The map index is set on an atom with property CDKConstants.ATOM_ATOM_MAPPING using IChemObject.setProperty(Object, Object).
      See Also:
    • AtomicMass

      public static final int AtomicMass
      Output atomic mass on atoms. For historical reasons the atomic mass is often set on all atoms in a CDK molecule. Therefore to avoid SMILES like [12CH3][12CH2][16OH] major isotopes are not generated. If you wish to generate SMILES with the major isotopes please use the flag AtomicMassStrict this will output all mass numbers and only be omitted when the mass is unset (null).
      See Also:
    • UseAromaticSymbols

      public static final int UseAromaticSymbols
      Writes aromatic atoms as lower case letters. For portability this option is not recommended.
      See Also:
    • StereoTetrahedral

      public static final int StereoTetrahedral
      Output tetrahedral stereochemistry on atoms as @ and @@.
      See Also:
    • StereoCisTrans

      public static final int StereoCisTrans
      Output cis-trans stereochemistry specified by directional \ of / bonds.
      See Also:
    • StereoExTetrahedral

      public static final int StereoExTetrahedral
      Output extended tetrahedral stereochemistry on atoms as @ and @@. Extended tetrahedral captures rotations around a cumulated carbon: CC=[C@]=CC.
      See Also:
    • StereoExCisTrans

      public static final int StereoExCisTrans
      See Also:
    • AtomicMassStrict

      @Deprecated public static final int AtomicMassStrict
      no longer needed, default CDK behaviour is now to pass through mass numbers if non-null
      Generate SMILES with the major isotopes, only omit mass numbers when it is unset.
      See Also:
    • Stereo

      public static final int Stereo
      Output supported stereochemistry types.
      See Also:
    • Cx2dCoordinates

      public static final int Cx2dCoordinates
      Output 2D coordinates.
      See Also:
    • Cx3dCoordinates

      public static final int Cx3dCoordinates
      Output 3D coordinates.
      See Also:
    • CxCoordinates

      public static final int CxCoordinates
      Output either 2D/3D coordinates.
      See Also:
    • CxAtomLabel

      public static final int CxAtomLabel
      Output atom labels, atom labels are specified by IPseudoAtom.getLabel().
      See Also:
    • CxAtomValue

      public static final int CxAtomValue
      Output atom values, atom values are specified by the property CDKConstants.COMMENT using IChemObject.setProperty(Object, Object)
      See Also:
    • CxRadical

      public static final int CxRadical
      Output radicals, radicals are specified by IAtomContainer.getConnectedSingleElectronsCount(IAtom)
      See Also:
    • CxMulticenter

      public static final int CxMulticenter
      Output multicenter bonds, positional variation is specified with Sgroups of the type SgroupType.ExtMulticenter.
      See Also:
    • CxPolymer

      public static final int CxPolymer
      Output polymer repeat units is specified with Sgroups.
      See Also:
    • CxFragmentGroup

      public static final int CxFragmentGroup
      Output fragment grouping for reactions.
      See Also:
    • CxLigandOrder

      public static final int CxLigandOrder
      Output ligand order information.
      See Also:
    • AtomAtomMapRenumber

      public static final int AtomAtomMapRenumber
      Renumber AtomAtomMaps during canonical generation
      See Also:
    • CxDataSgroups

      public static final int CxDataSgroups
      Output data Sgroups.
      See Also:
    • CxEnhancedStereo

      public static final int CxEnhancedStereo
      Output enhanced stereo.
      See Also:
    • CxSmiles

      public static final int CxSmiles
      Output CXSMILES layers.
      See Also:
    • CxSmilesWithCoords

      public static final int CxSmilesWithCoords
      Output CXSMILES layers and coordinates.
      See Also:
    • Generic

      public static final int Generic
      Output non-canonical SMILES without stereochemistry, atomic masses.
      See Also:
    • Unique

      public static final int Unique
      Output canonical SMILES without stereochemistry, atomic masses.
      See Also:
    • Isomeric

      public static final int Isomeric
      Output non-canonical SMILES with stereochemistry, atomic masses.
      See Also:
    • Absolute

      public static final int Absolute
      Output canonical SMILES with stereochemistry, atomic masses.
      See Also:
    • Default

      public static final int Default
      Default SMILES output write Stereochemistry, Atomic Mass, and CXSMILES layers. The ordering is not canonical.
      See Also:
    • UniversalSmiles

      public static final int UniversalSmiles
      Output canonical SMILES with stereochemistry and atomic masses, This output uses the InChI labelling algorithm to generate a 'Universal SMILES' [O'Boyle, Noel. Journal of Cheminformatics. 2012. 4].
      Unfortunately there are several issues and general use is not recommended:
      • MAJOR: Molecules with delocalised charges are generally non-canonical, e.g. C(\C=C\N1CCCC1)=C/c2[n+](c3c(n2CC)nc4ccccc4n3)CC will generate two different SMILES depending on input order
      • MINOR: Double bond '/' '\' assignment is different from the original paper (O'Boyle) and will not match universal SMILES generated by Open Babel
      • MINOR: SMILES with '*' atoms can not be canonicalised by default, to avoid this we use the 'Rf' atom as a substitute. Structures with an 'Rf' atom can still be generated providing there are no '*' atoms.
      • MINOR: The InChI library (v1.03) is not thread safe
      See Also: