Class DBRef

  • All Implemented Interfaces:
    java.io.Serializable, PDBRecord

    public class DBRef
    extends java.lang.Object
    implements PDBRecord, java.io.Serializable
    A class to represent database cross references. This is just a simple bean that contains the infor from one DBREF line
    Since:
    4:56:14 PM
    Version:
    %I% %G%
    Author:
    Andreas Prlic
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      DBRef()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getChainId()
      The chain ID of the corresponding chain.
      java.lang.String getDatabase()
      The database of the db-ref.
      java.lang.String getDbAccession()
      Sequence database accession code.
      java.lang.String getDbIdCode()
      Sequence database identification code.
      int getDbSeqBegin()
      Initial sequence number of the database seqment.
      int getDbSeqEnd()
      Ending sequence position of the database segment.
      java.lang.Long getId()
      Get the ID used by Hibernate.
      char getIdbnsBegin()
      Insertion code of initial residue of the segment, if PDB is the reference.
      char getIdbnsEnd()
      Insertion code of the ending residue of the segment, if PDB is the reference.
      java.lang.String getIdCode()
      get the idCode for this entry
      char getInsertBegin()
      Initial insertion code of the PDB sequence segment.
      char getInsertEnd()
      Ending insertion code of the PDB sequence segment.
      Structure getParent()
      Get the structure object that this DBRef relates to.
      int getSeqBegin()
      Initial sequence number of the PDB sequence segment.
      int getSeqEnd()
      Ending sequence number of the PDB sequence segment.
      void setChainId​(java.lang.String chainId)
      The chain ID of the corresponding chain.
      void setDatabase​(java.lang.String database)
      Specifies the database value.
      void setDbAccession​(java.lang.String dbAccession)
      Sequence database accession code.
      void setDbIdCode​(java.lang.String dbIdCode)
      Sequence database identification code.
      void setDbSeqBegin​(int dbSeqBegin)
      Initial sequence number of the database seqment.
      void setDbSeqEnd​(int dbSeqEnd)
      The begin of the sequence position in the database
      void setId​(java.lang.Long id)
      Set the ID used by Hibernate.
      void setIdbnsBegin​(char idbnsBegin)
      Insertion code of initial residue of the segment, if PDB is the reference.
      void setIdbnsEnd​(char idbnsEnd)
      Insertion code of the ending residue of the segment, if PDB is the reference.
      void setIdCode​(java.lang.String idCode)
      Set the idCode for this entry.
      void setInsertBegin​(char insertBegin)
      Initial insertion code of the PDB sequence segment.
      void setInsertEnd​(char insertEnd)
      Ending insertion code of the PDB sequence segment.
      void setParent​(Structure s)
      Set the structure object that this DBRef relates to.
      void setSeqBegin​(int seqbegin)
      Initial sequence number of the PDB sequence segment.
      void setSeqEnd​(int seqEnd)
      Ending sequence number of the PDB sequence segment.
      java.lang.String toPDB()
      Convert the DBRef object to a DBREF record as it is used in PDB files
      void toPDB​(java.lang.StringBuffer buf)
      Append the PDB representation of this DBRef to the provided StringBuffer
      java.lang.String toString()
      String representation of a DBRef.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • DBRef

        public DBRef()
    • Method Detail

      • getId

        public java.lang.Long getId()
        Get the ID used by Hibernate.
        Returns:
        the ID used by Hibernate
        See Also:
        setId(Long)
      • setId

        public void setId​(java.lang.Long id)
        Set the ID used by Hibernate.
        Parameters:
        id - the id assigned by Hibernate
        See Also:
        getId()
      • setParent

        public void setParent​(Structure s)
        Set the structure object that this DBRef relates to.
        Parameters:
        s - a structure object
        See Also:
        getParent()
      • getParent

        public Structure getParent()
        Get the structure object that this DBRef relates to.
        Returns:
        s a structure object
        See Also:
        setParent(Structure)
      • toPDB

        public java.lang.String toPDB()
        Convert the DBRef object to a DBREF record as it is used in PDB files
        Specified by:
        toPDB in interface PDBRecord
        Returns:
        a PDB - DBREF formatted line
      • toPDB

        public void toPDB​(java.lang.StringBuffer buf)
        Append the PDB representation of this DBRef to the provided StringBuffer
        Specified by:
        toPDB in interface PDBRecord
        Parameters:
        buf - the StringBuffer to write to.
      • toString

        public java.lang.String toString()
        String representation of a DBRef.
        Overrides:
        toString in class java.lang.Object
        Returns:
        a String
      • getIdCode

        public java.lang.String getIdCode()
        get the idCode for this entry
        Returns:
        the idCode
        See Also:
        setIdCode(String)
      • setIdCode

        public void setIdCode​(java.lang.String idCode)
        Set the idCode for this entry.
        Parameters:
        idCode - the idCode for this entry
        See Also:
        getIdCode()
      • getChainId

        public java.lang.String getChainId()
        The chain ID of the corresponding chain.
        Returns:
        chainId the ID of the corresponding chain.
      • setChainId

        public void setChainId​(java.lang.String chainId)
        The chain ID of the corresponding chain.
        Parameters:
        chainId - the ID of the corresponding chain
        See Also:
        getChainId()
      • getDatabase

        public java.lang.String getDatabase()
        The database of the db-ref. uses the abbreviation as provided in the PDB files:
           Database name                         database
                                                                                 (code in columns 27 - 32)
                ----------------------------------------------------------
                GenBank                               GB
                Protein Data Bank                     PDB
                Protein Identification Resource       PIR
                SWISS-PROT                            SWS
                TREMBL                                TREMBL
                UNIPROT                               UNP
                
        Returns:
        name of database of this DBRef
        See Also:
        setDatabase(String)
      • setDatabase

        public void setDatabase​(java.lang.String database)
        Specifies the database value.
        Parameters:
        database - the database
        See Also:
        getDatabase()
      • getDbAccession

        public java.lang.String getDbAccession()
        Sequence database accession code.
        Returns:
        the dbAccession
        See Also:
        setDbAccession(String)
      • setDbAccession

        public void setDbAccession​(java.lang.String dbAccession)
        Sequence database accession code.
        Parameters:
        dbAccession - the dbAccession
        See Also:
        getDbAccession()
      • getDbIdCode

        public java.lang.String getDbIdCode()
        Sequence database identification code.
        Returns:
        the dbIdCode
        See Also:
        setDbIdCode(String)
      • setDbIdCode

        public void setDbIdCode​(java.lang.String dbIdCode)
        Sequence database identification code.
        Parameters:
        dbIdCode - identification code
        See Also:
        getDbIdCode()
      • getDbSeqBegin

        public int getDbSeqBegin()
        Initial sequence number of the database seqment.
        Returns:
        position
        See Also:
        setDbSeqBegin(int)
      • setDbSeqBegin

        public void setDbSeqBegin​(int dbSeqBegin)
        Initial sequence number of the database seqment.
        Parameters:
        dbSeqBegin - a sequence position
        See Also:
        getDbSeqBegin()
      • getDbSeqEnd

        public int getDbSeqEnd()
        Ending sequence position of the database segment.
        Returns:
        dbSeqEnd
        See Also:
        setDbSeqEnd(int)
      • setDbSeqEnd

        public void setDbSeqEnd​(int dbSeqEnd)
        The begin of the sequence position in the database
        Parameters:
        dbSeqEnd - sequence position
        See Also:
        getDbSeqEnd()
      • getIdbnsBegin

        public char getIdbnsBegin()
        Insertion code of initial residue of the segment, if PDB is the reference.
        Returns:
        idbnsBegin isnertion code
        See Also:
        setIdbnsBegin(char)
      • setIdbnsBegin

        public void setIdbnsBegin​(char idbnsBegin)
        Insertion code of initial residue of the segment, if PDB is the reference.
        Parameters:
        idbnsBegin - insertion code
        See Also:
        getIdbnsBegin()
      • getIdbnsEnd

        public char getIdbnsEnd()
        Insertion code of the ending residue of the segment, if PDB is the reference.
        Returns:
        idbnsEnd insertion code
        See Also:
        setIdbnsEnd(char)
      • setIdbnsEnd

        public void setIdbnsEnd​(char idbnsEnd)
        Insertion code of the ending residue of the segment, if PDB is the reference.
        Parameters:
        idbnsEnd - the insertion code
        See Also:
        setIdbnsEnd(char)
      • getInsertBegin

        public char getInsertBegin()
        Initial insertion code of the PDB sequence segment.
        Returns:
        insertBegin
        See Also:
        setInsertBegin(char)
      • setInsertBegin

        public void setInsertBegin​(char insertBegin)
        Initial insertion code of the PDB sequence segment.
        Parameters:
        insertBegin -
        See Also:
        getInsertBegin()
      • getInsertEnd

        public char getInsertEnd()
        Ending insertion code of the PDB sequence segment.
        Returns:
        insertEnd insertion code
        See Also:
        setInsertEnd(char)
      • setInsertEnd

        public void setInsertEnd​(char insertEnd)
        Ending insertion code of the PDB sequence segment.
        Parameters:
        insertEnd - insertEnd
        See Also:
        getInsertEnd()
      • getSeqBegin

        public int getSeqBegin()
        Initial sequence number of the PDB sequence segment.
        Returns:
        start seq. position
        See Also:
        setSeqBegin(int)
      • setSeqBegin

        public void setSeqBegin​(int seqbegin)
        Initial sequence number of the PDB sequence segment.
        Parameters:
        seqbegin - start seq. position
        See Also:
        getSeqBegin()
      • getSeqEnd

        public int getSeqEnd()
        Ending sequence number of the PDB sequence segment.
        Returns:
        sequence end position
        See Also:
        getSeqEnd()
      • setSeqEnd

        public void setSeqEnd​(int seqEnd)
        Ending sequence number of the PDB sequence segment.
        Parameters:
        seqEnd - sequence end position
        See Also:
        setSeqEnd(int)