Class Mol2Reader

  • All Implemented Interfaces:
    javajs.api.GenericLineReader

    public class Mol2Reader
    extends ForceFieldReader
    A minimal multi-file reader for TRIPOS SYBYL mol2 files.

    http://www.tripos.com/data/support/mol2.pdf see also http://www.tripos.com/mol2/atom_types.html PDB note: Note that mol2 format of PDB files is quite minimal. All we get is the PDB atom name, coordinates, residue number, and residue name No chain terminator, not chain designator, no element symbol. Chains based on numbering reset just labeled A B C D .... Z a b c d .... z

    • Field Detail

      • nAtoms

        private int nAtoms
      • ac

        private int ac
      • isPDB

        private boolean isPDB
      • lastSequenceNumber

        private int lastSequenceNumber
      • chainID

        private int chainID
    • Constructor Detail

      • Mol2Reader

        public Mol2Reader()
    • Method Detail

      • checkLine

        public boolean checkLine()
                          throws java.lang.Exception
        Overrides:
        checkLine in class AtomSetCollectionReader
        Returns:
        true if need to read new line
        Throws:
        java.lang.Exception
      • processMolecule

        private boolean processMolecule()
                                 throws java.lang.Exception
        Throws:
        java.lang.Exception
      • readAtoms

        private void readAtoms​(int ac)
                        throws java.lang.Exception
        Throws:
        java.lang.Exception
      • getPDBGroupLength

        private int getPDBGroupLength​(java.lang.String g3)
      • readBonds

        private void readBonds​(int bondCount)
                        throws java.lang.Exception
        Throws:
        java.lang.Exception
      • readResInfo

        private void readResInfo​(int resCount)
                          throws java.lang.Exception
        Throws:
        java.lang.Exception
      • readCrystalInfo

        private void readCrystalInfo()
                              throws java.lang.Exception
        Throws:
        java.lang.Exception