Class SmilesBond

  • All Implemented Interfaces:
    SimpleEdge

    public class SmilesBond
    extends Edge
    Bond in a SmilesMolecule
    • Constructor Detail

      • SmilesBond

        SmilesBond​(SmilesAtom atom1,
                   SmilesAtom atom2,
                   int bondType,
                   boolean isNot)
        SmilesBond constructor
        Parameters:
        atom1 - First atom
        atom2 - Second atom
        bondType - Bond type
        isNot -
    • Method Detail

      • getBondOrderString

        static java.lang.String getBondOrderString​(int order)
      • getBondTypeFromCode

        static int getBondTypeFromCode​(char code)
        Parameters:
        code - Bond code
        Returns:
        Bond type
      • setAtropType

        void setAtropType​(int nn)
      • setPrimitive

        public SmilesBond setPrimitive​(int i)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • set2

        void set2​(int bondType,
                  boolean isNot)
      • setAtom2

        void setAtom2​(SmilesAtom atom,
                      SmilesSearch molecule)
        from parse ring
        Parameters:
        atom -
        molecule -
      • isFromPreviousTo

        boolean isFromPreviousTo​(SmilesAtom atom)
        Check to see if this is the bond to the previous atom
        Parameters:
        atom -
        Returns:
        TRUE if other atom is previous atom
      • getBondType

        int getBondType()
      • getValence

        int getValence()
      • getAtomIndex1

        public int getAtomIndex1()
        Specified by:
        getAtomIndex1 in class Edge
      • getAtomIndex2

        public int getAtomIndex2()
        Specified by:
        getAtomIndex2 in class Edge
      • isHydrogen

        public boolean isHydrogen()
        Specified by:
        isHydrogen in class Edge
      • switchAtoms

        void switchAtoms()
        Ensure that atom ordering is proper. possibly not fully tested
      • getRealCovalentOrder

        public int getRealCovalentOrder()
      • getMatchingBond

        public Edge getMatchingBond()