Class JniInchiStereo0D

java.lang.Object
net.sf.jniinchi.JniInchiStereo0D

public class JniInchiStereo0D extends Object
Encapsulates properites of InChI Stereo Parity. See inchi_api.h.
  • Field Details

    • NO_ATOM

      public static final int NO_ATOM
      Indicates non-existent (central) atom. Value from inchi_api.h.
      See Also:
    • neighbors

      private JniInchiAtom[] neighbors
      Neighbouring atoms.
    • centralAtom

      private JniInchiAtom centralAtom
      Central atom.
    • type

      private INCHI_STEREOTYPE type
      Stereo parity type.
    • parity

      private INCHI_PARITY parity
      Parity.
    • disconParity

      private INCHI_PARITY disconParity
      Second parity (for disconnected systems).
  • Constructor Details

  • Method Details

    • setDisconnectedParity

      public void setDisconnectedParity(INCHI_PARITY parity)
      Set second parity (for disconnected systems)
      Parameters:
      parity -
    • getCentralAtom

      public JniInchiAtom getCentralAtom()
      Returns central atom of stereo parity.
      Returns:
    • getNeighbors

      public JniInchiAtom[] getNeighbors()
      Returns neighboring atoms of stereo parity.
      Returns:
    • getNeighbor

      public JniInchiAtom getNeighbor(int i)
    • getParity

      public INCHI_PARITY getParity()
      Returns parity.
      Returns:
    • getDisconnectedParity

      public INCHI_PARITY getDisconnectedParity()
      Returns disconnected parity.
      Returns:
    • getStereoType

      public INCHI_STEREOTYPE getStereoType()
      Returns type of stereochemistry.
      Returns:
    • getDebugString

      public String getDebugString()
      Generates string representation of information on stereo parity, for debugging purposes.
    • debug

      public void debug()
      Outputs information on stereo parity, for debugging purposes.
    • createNewTetrahedralStereo0D

      public static JniInchiStereo0D createNewTetrahedralStereo0D(JniInchiAtom atC, JniInchiAtom at0, JniInchiAtom at1, JniInchiAtom at2, JniInchiAtom at3, INCHI_PARITY parity)

      Convenience method for generating 0D stereo parities at tetrahedral atom centres.

      Usage notes from inchi_api.h:

        4 neighbors
      
                 X                    neighbor[4] : {#W, #X, #Y, #Z}
                 |                    central_atom: #A
              W--A--Y                 type        : INCHI_StereoType_Tetrahedral
                 |
                 Z
        parity: if (X,Y,Z) are clockwize when seen from W then parity is 'e' otherwise 'o'
        Example (see AXYZW above): if W is above the plane XYZ then parity = 'e'
      
        3 neighbors
      
                   Y          Y       neighbor[4] : {#A, #X, #Y, #Z}
                  /          /        central_atom: #A
              X--A  (e.g. O=S   )     type        : INCHI_StereoType_Tetrahedral
                  \          \
                   Z          Z
      
        parity: if (X,Y,Z) are clockwize when seen from A then parity is 'e',
                                                               otherwise 'o'
        unknown parity = 'u'
        Example (see AXYZ above): if A is above the plane XYZ then parity = 'e'
        This approach may be used also in case of an implicit H attached to A.
      
        ==============================================
        Note. Correspondence to CML 0D stereo parities
        ==============================================
        a list of 4 atoms corresponds to CML atomRefs4
      
        tetrahedral atom
        ================
        CML atomParity > 0 <=> INCHI_PARITY_EVEN
        CML atomParity < 0 <=> INCHI_PARITY_ODD
      
                                     | 1   1   1   1  |  where xW is x-coordinate of
                                     | xW  xX  xY  xZ |  atom W, etc. (xyz is a
        CML atomParity = determinant | yW  yX  yY  yZ |  'right-handed' Cartesian
                                     | zW  zX  xY  zZ |  coordinate system)
       
      Parameters:
      atC - Central atom
      at0 - Neighbour atom 0
      at1 - Neighbour atom 1
      at2 - Neighbour atom 2
      at3 - Neighbour atom 3
      parity - Parity
    • createNewDoublebondStereo0D

      public static JniInchiStereo0D createNewDoublebondStereo0D(JniInchiAtom at0, JniInchiAtom at1, JniInchiAtom at2, JniInchiAtom at3, INCHI_PARITY parity)

      Convenience method for generating 0D stereo parities at stereogenic double bonds.

      Usage notes from inchi_api.h:

        =============================================
        stereogenic bond >A=B< or cumulene >A=C=C=B<
        =============================================
      
                                    neighbor[4]  : {#X,#A,#B,#Y} in this order
        X                           central_atom : NO_ATOM
         \            X      Y      type         : INCHI_StereoType_DoubleBond
          A==B         \    /
              \         A==B
               Y
      
        parity= 'e'    parity= 'o'   unknown parity = 'u'
      
        ==============================================
        Note. Correspondence to CML 0D stereo parities
        ==============================================
      
        stereogenic double bond and (not yet defined in CML) cumulenes
        ==============================================================
        CML 'C' (cis)      <=> INCHI_PARITY_ODD
        CML 'T' (trans)    <=> INCHI_PARITY_EVEN
       
      Parameters:
      at0 - Neighbour atom 0
      at1 - Neighbour atom 1
      at2 - Neighbour atom 2
      at3 - Neighbour atom 3
      parity - Parity
      Returns:
    • getInchiStereoType

      int getInchiStereoType()
    • getInchiParity

      int getInchiParity()