Class SimpleMMcifConsumer
- java.lang.Object
-
- org.biojava.bio.structure.io.mmcif.SimpleMMcifConsumer
-
- All Implemented Interfaces:
MMcifConsumer
public class SimpleMMcifConsumer extends java.lang.Object implements MMcifConsumer
A MMcifConsumer implementation that build a in-memory representation of the content of a mmcif file as a BioJava Structure object.- Since:
- 1.7
- Author:
- Andreas Prlic
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.logging.Loggerlogger
-
Constructor Summary
Constructors Constructor Description SimpleMMcifConsumer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddocumentEnd()called at end of documentvoiddocumentStart()Start the parsingStructuregetStructure()This method will return the parsed protein structure, once the parsing has been finishedbooleanisAlignSeqRes()Flag if the SEQRES amino acids should be aligned with the ATOM amino acids.booleanisParseCAOnly()voidnewAtomSite(AtomSite atom)A new AtomSite record has been read.voidnewChemComp(ChemComp c)voidnewDatabasePDBremark(DatabasePDBremark remark)voidnewDatabasePDBrev(DatabasePDBrev dbrev)voidnewEntity(Entity entity)voidnewEntityPolySeq(EntityPolySeq epolseq)The EntityPolySeq object provide the amino acid sequence objects for the Entities.voidnewExptl(Exptl exptl)voidnewGenericData(java.lang.String category, java.util.List<java.lang.String> loopFields, java.util.List<java.lang.String> lineData)This method is called if no particular handler for the provided cif category has been implemented so far.voidnewPdbxEntityNonPoly(PdbxEntityNonPoly pen)voidnewPdbxNonPolyScheme(PdbxNonPolyScheme ppss)voidnewPdbxPolySeqScheme(PdbxPolySeqScheme ppss)voidnewRefine(Refine r)voidnewStructAsym(StructAsym sasym)voidnewStructKeywords(StructKeywords kw)voidnewStructRef(StructRef sref)voidnewStructRefSeq(StructRefSeq sref)create a DBRef record from the StrucRefSeq record:voidsetAlignSeqRes(boolean alignSeqRes)define if the SEQRES in the structure should be aligned with the ATOM records if yes, the AminoAcids in structure.getSeqRes will have the coordinates set.voidsetParseCAOnly(boolean parseCAOnly)voidsetStruct(Struct struct)
-
-
-
Method Detail
-
isParseCAOnly
public boolean isParseCAOnly()
-
setParseCAOnly
public void setParseCAOnly(boolean parseCAOnly)
-
newEntity
public void newEntity(Entity entity)
- Specified by:
newEntityin interfaceMMcifConsumer
-
newStructAsym
public void newStructAsym(StructAsym sasym)
- Specified by:
newStructAsymin interfaceMMcifConsumer
-
newStructKeywords
public void newStructKeywords(StructKeywords kw)
- Specified by:
newStructKeywordsin interfaceMMcifConsumer
-
setStruct
public void setStruct(Struct struct)
- Specified by:
setStructin interfaceMMcifConsumer
-
newAtomSite
public void newAtomSite(AtomSite atom)
Description copied from interface:MMcifConsumerA new AtomSite record has been read. Contains the Atom data- Specified by:
newAtomSitein interfaceMMcifConsumer
-
documentStart
public void documentStart()
Start the parsing- Specified by:
documentStartin interfaceMMcifConsumer
-
isAlignSeqRes
public boolean isAlignSeqRes()
Flag if the SEQRES amino acids should be aligned with the ATOM amino acids.- Returns:
- flag if SEQRES - ATOM amino acids alignment is enabled
-
setAlignSeqRes
public void setAlignSeqRes(boolean alignSeqRes)
define if the SEQRES in the structure should be aligned with the ATOM records if yes, the AminoAcids in structure.getSeqRes will have the coordinates set.- Parameters:
alignSeqRes-
-
documentEnd
public void documentEnd()
Description copied from interface:MMcifConsumercalled at end of document- Specified by:
documentEndin interfaceMMcifConsumer
-
getStructure
public Structure getStructure()
This method will return the parsed protein structure, once the parsing has been finished- Returns:
- a BioJava protein structure object
-
newDatabasePDBrev
public void newDatabasePDBrev(DatabasePDBrev dbrev)
- Specified by:
newDatabasePDBrevin interfaceMMcifConsumer
-
newDatabasePDBremark
public void newDatabasePDBremark(DatabasePDBremark remark)
- Specified by:
newDatabasePDBremarkin interfaceMMcifConsumer
-
newRefine
public void newRefine(Refine r)
- Specified by:
newRefinein interfaceMMcifConsumer
-
newExptl
public void newExptl(Exptl exptl)
- Specified by:
newExptlin interfaceMMcifConsumer
-
newStructRef
public void newStructRef(StructRef sref)
- Specified by:
newStructRefin interfaceMMcifConsumer
-
newStructRefSeq
public void newStructRefSeq(StructRefSeq sref)
create a DBRef record from the StrucRefSeq record:PDB record DBREF Field Name mmCIF Data Item Section n.a. PDB_ID_Code _struct_ref_seq.pdbx_PDB_id_code Strand_ID _struct_ref_seq.pdbx_strand_id Begin_Residue_Number _struct_ref_seq.pdbx_auth_seq_align_beg Begin_Ins_Code _struct_ref_seq.pdbx_seq_align_beg_ins_code End_Residue_Number _struct_ref_seq.pdbx_auth_seq_align_end End_Ins_Code _struct_ref_seq.pdbx_seq_align_end_ins_code Database _struct_ref.db_name Database_Accession_No _struct_ref_seq.pdbx_db_accession Database_ID_Code _struct_ref.db_code Database_Begin_Residue_Number _struct_ref_seq.db_align_beg Databaes_Begin_Ins_Code _struct_ref_seq.pdbx_db_align_beg_ins_code Database_End_Residue_Number _struct_ref_seq.db_align_end Databaes_End_Ins_Code _struct_ref_seq.pdbx_db_align_end_ins_code
- Specified by:
newStructRefSeqin interfaceMMcifConsumer
-
newEntityPolySeq
public void newEntityPolySeq(EntityPolySeq epolseq)
The EntityPolySeq object provide the amino acid sequence objects for the Entities. Later on the entities are mapped to the BioJava Chain and Compound objects.- Specified by:
newEntityPolySeqin interfaceMMcifConsumer- Parameters:
epolseq- the EntityPolySeq record for one amino acid
-
newPdbxPolySeqScheme
public void newPdbxPolySeqScheme(PdbxPolySeqScheme ppss)
- Specified by:
newPdbxPolySeqSchemein interfaceMMcifConsumer
-
newPdbxNonPolyScheme
public void newPdbxNonPolyScheme(PdbxNonPolyScheme ppss)
- Specified by:
newPdbxNonPolySchemein interfaceMMcifConsumer
-
newPdbxEntityNonPoly
public void newPdbxEntityNonPoly(PdbxEntityNonPoly pen)
- Specified by:
newPdbxEntityNonPolyin interfaceMMcifConsumer
-
newChemComp
public void newChemComp(ChemComp c)
- Specified by:
newChemCompin interfaceMMcifConsumer
-
newGenericData
public void newGenericData(java.lang.String category, java.util.List<java.lang.String> loopFields, java.util.List<java.lang.String> lineData)Description copied from interface:MMcifConsumerThis method is called if no particular handler for the provided cif category has been implemented so far.- Specified by:
newGenericDatain interfaceMMcifConsumer- Parameters:
category- The category that is being processed.loopFields- the fields of this category.lineData- the data that is being provided.
-
-