00001
00002
00003
00004
00005 #ifndef BALL_FORMAT_PDBFILE_H
00006 #define BALL_FORMAT_PDBFILE_H
00007
00008 #ifndef BALL_CONCEPT_PROPERTY_H
00009 # include <BALL/CONCEPT/property.h>
00010 #endif
00011
00012 #ifndef BALL_FORMAT_GENERICMOLFILE_H
00013 # include <BALL/FORMAT/genericMolFile.h>
00014 #endif
00015
00016 #ifndef BALL_DATATYPE_OPTIONS_H
00017 # include <BALL/DATATYPE/options.h>
00018 #endif
00019
00020 #ifndef BALL_DATATYPE_QUADRUPLE_H
00021 # include <BALL/DATATYPE/quadruple.h>
00022 #endif
00023
00024 #ifndef BALL_FORMAT_PDBDEFS_H
00025 # include <BALL/FORMAT/PDBdefs.h>
00026 #endif
00027
00028 #ifndef BALL_FORMAT_PDBINFO_H
00029 # include <BALL/FORMAT/PDBInfo.h>
00030 #endif
00031
00032 #ifndef BALL_KERNEL_PDBAtom_H
00033 # include <BALL/KERNEL/PDBAtom.h>
00034 #endif
00035
00036 #ifndef BALL_KERNEL_SYSTEM_H
00037 # include <BALL/KERNEL/system.h>
00038 #endif
00039
00040 #ifndef BALL_KERNEL_RESIDUE_H
00041 # include <BALL/KERNEL/residue.h>
00042 #endif
00043
00044 #ifndef BALL_KERNEL_SECONDARYSTRUCTURE_H
00045 # include <BALL/KERNEL/secondaryStructure.h>
00046 #endif
00047
00048 #if defined(BALL_HAS_UNORDERED_MAP) || defined(BALL_HAS_HASH_MAP)
00049 #ifdef BALL_EXTEND_HASH_IN_STD_NS
00050 namespace std
00051 {
00052 #endif
00053 namespace BALL_MAP_NAMESPACE {
00054 template<>
00055 struct hash<BALL::Quadruple<BALL::String, BALL::PDB::Character, BALL::PDB::Integer, BALL::PDB::AChar> >
00056 {
00057 size_t
00058 operator()(const BALL::Quadruple<BALL::String, BALL::PDB::Character, BALL::PDB::Integer, BALL::PDB::AChar>& f) const
00059 { return (size_t)f.third; }
00060 };
00061 }
00062 #ifdef BALL_EXTEND_HASH_IN_STD_NS
00063 }
00064 #endif
00065 #endif
00066
00067 namespace BALL
00068 {
00069
00074 class BALL_EXPORT PDBFile
00075 : public GenericMolFile,
00076 public PropertyManager
00077 {
00078 public:
00079
00085 struct BALL_EXPORT Option
00086 {
00093 static const char* VERBOSITY;
00094
00101 static const char* STRICT_LINE_CHECKING;
00102
00110 static const char* CHOOSE_MODEL;
00111
00117 static const char* STORE_SKIPPED_RECORDS;
00118
00124 static const char* IGNORE_XPLOR_PSEUDO_ATOMS;
00125
00131 static const char* PARSE_PARTIAL_CHARGES;
00132 };
00133
00136 struct BALL_EXPORT Default
00137 {
00142 static const Index VERBOSITY;
00143
00148 static const bool STRICT_LINE_CHECKING;
00149
00154 static const Index CHOOSE_MODEL;
00155
00159 static const bool STORE_SKIPPED_RECORDS;
00160
00164 static const bool IGNORE_XPLOR_PSEUDO_ATOMS;
00165
00169 static const bool PARSE_PARTIAL_CHARGES;
00170 };
00171
00175
00176 Options options;
00178 PDBInfo info;
00180
00184
00185 PDBFile();
00186
00188 PDBFile(const String& filename, File::OpenMode open_mode = std::ios::in) throw(Exception::FileNotFound);
00189
00191 PDBFile(const Options& new_options);
00192
00194 virtual ~PDBFile();
00196
00200
00202 virtual void clear(int state);
00203
00205 virtual void clear();
00206
00208
00212
00214 virtual float getVersion() const;
00215
00220 void selectModel(Index index);
00221
00233 void selectAltLocationIndicator(char c);
00234
00236 Index getSelectedModel() const;
00237
00239 void selectAllModels();
00240
00242 Index getCurrentModel() const;
00243
00245 char* getRecordString();
00246
00248 const char* getRecordString() const;
00249
00251 Index getRecordNumber() const;
00252
00254 PDB::RecordType getRecordType() const;
00255
00259 virtual const char* getAtomElementSymbol
00260 (const PDB::Atom atom_name,
00261 PDB::Atom element_symbol);
00262
00264 virtual const char* getAtomName
00265 (const PDB::Atom atom_name);
00266
00268 virtual char getAtomRemotenessIndicator
00269 (const PDB::Atom atom_name);
00270
00272 virtual short getAtomBranchDesignator
00273 (const PDB::Atom atom_name);
00274
00276 Size countRecordFields() const;
00277
00281 Size countRecord
00282 (PDB::RecordType record_type,
00283 bool from_begin_of_file = true);
00284
00287 Size countRecords
00288 (bool from_begin_of_file = true);
00290
00297
00298 bool parseLine(const char* line, Size size, const char* format_string, ...);
00299
00301 bool readLine(char* line, Size size, bool extract_values);
00302
00304 bool readFirstRecord(bool read_values = true);
00305
00307 bool readNextRecord(bool read_values = true);
00308
00313 bool readRecords();
00314
00319 virtual bool readUnknownRecord(const char* line);
00320
00323 virtual bool readInvalidRecord(const char* line);
00324
00333 bool skipCurrentRecord();
00334
00336 virtual bool interpretRecord(const PDB::RecordANISOU& record);
00337 virtual bool fillRecord(const char* line, Size size, PDB::RecordANISOU& record);
00338 virtual bool parseRecordANISOU(const char* line, Size size);
00339
00341 virtual bool interpretRecord(const PDB::RecordATOM& record);
00342 virtual bool fillRecord(const char* line, Size size, PDB::RecordATOM& record);
00343 virtual bool parseRecordATOM(const char* line, Size size);
00344
00346 virtual bool interpretRecord(const PDB::RecordAUTHOR& record);
00347 virtual bool fillRecord(const char* line, Size size, PDB::RecordAUTHOR& record);
00348 virtual bool parseRecordAUTHOR(const char* line, Size size);
00349
00351 virtual bool interpretRecord(const PDB::RecordCAVEAT& record);
00352 virtual bool fillRecord(const char* line, Size size, PDB::RecordCAVEAT& record);
00353 virtual bool parseRecordCAVEAT(const char* line, Size size);
00354
00356 virtual bool interpretRecord(const PDB::RecordCISPEP& record);
00357 virtual bool fillRecord(const char* line, Size size, PDB::RecordCISPEP& record);
00358 virtual bool parseRecordCISPEP(const char* line, Size size);
00359
00361 virtual bool interpretRecord(const PDB::RecordCOMPND& record);
00362 virtual bool fillRecord(const char* line, Size size, PDB::RecordCOMPND& record);
00363 virtual bool parseRecordCOMPND(const char* line, Size size);
00364
00366 virtual bool interpretRecord(const PDB::RecordCONECT& record);
00367 virtual bool fillRecord(const char* line, Size size, PDB::RecordCONECT& record);
00368 virtual bool parseRecordCONECT(const char* line, Size size);
00369
00373 virtual bool interpretRecord(const PDB::RecordCRYST1& record);
00374 virtual bool fillRecord(const char* line, Size size, PDB::RecordCRYST1& record);
00375 virtual bool parseRecordCRYST1(const char* line, Size size);
00376
00378 virtual bool interpretRecord(const PDB::RecordDBREF& record);
00379 virtual bool fillRecord(const char* line, Size size, PDB::RecordDBREF& record);
00380 virtual bool parseRecordDBREF(const char* line, Size size);
00381
00383 virtual bool interpretRecord(const PDB::RecordEND& record);
00384 virtual bool fillRecord(const char* line, Size size, PDB::RecordEND& record);
00385 virtual bool parseRecordEND(const char* line, Size size);
00386
00388 virtual bool interpretRecord(const PDB::RecordENDMDL& record);
00389 virtual bool fillRecord(const char* line, Size size, PDB::RecordENDMDL& record);
00390 virtual bool parseRecordENDMDL(const char* line, Size size);
00391
00393 virtual bool interpretRecord(const PDB::RecordEXPDTA& record);
00394 virtual bool fillRecord(const char* line, Size size, PDB::RecordEXPDTA& record);
00395 virtual bool parseRecordEXPDTA(const char* line, Size size);
00396
00400 virtual bool interpretRecord(const PDB::RecordFORMUL& record);
00401 virtual bool fillRecord(const char* line, Size size, PDB::RecordFORMUL& record);
00402 virtual bool parseRecordFORMUL(const char* line, Size size);
00403
00405 virtual bool interpretRecord(const PDB::RecordFTNOTE& record);
00406 virtual bool fillRecord(const char* line, Size size, PDB::RecordFTNOTE& record);
00407 virtual bool parseRecordFTNOTE(const char* line, Size size);
00408
00412 virtual bool interpretRecord(const PDB::RecordHEADER& record);
00413 virtual bool fillRecord(const char* line, Size size, PDB::RecordHEADER& record);
00414 virtual bool parseRecordHEADER(const char* line, Size size);
00415
00417 virtual bool interpretRecord(const PDB::RecordHELIX& record);
00418 virtual bool fillRecord(const char* line, Size size, PDB::RecordHELIX& record);
00419 virtual bool parseRecordHELIX(const char* line, Size size);
00420
00422 virtual bool interpretRecord(const PDB::RecordHET& record);
00423 virtual bool fillRecord(const char* line, Size size, PDB::RecordHET& record);
00424 virtual bool parseRecordHET(const char* line, Size size);
00425
00427 virtual bool interpretRecord(const PDB::RecordHETATM& record);
00428 virtual bool fillRecord(const char* line, Size size, PDB::RecordHETATM& record);
00429 virtual bool parseRecordHETATM(const char* line, Size size);
00430
00432 virtual bool interpretRecord(const PDB::RecordHETNAM& record);
00433 virtual bool fillRecord(const char* line, Size size, PDB::RecordHETNAM& record);
00434 virtual bool parseRecordHETNAM(const char* line, Size size);
00435
00437 virtual bool interpretRecord(const PDB::RecordHETSYN& record);
00438 virtual bool fillRecord(const char* line, Size size, PDB::RecordHETSYN& record);
00439 virtual bool parseRecordHETSYN(const char* line, Size size);
00440
00442 virtual bool interpretRecord(const PDB::RecordHYDBND& record);
00443 virtual bool fillRecord(const char* line, Size size, PDB::RecordHYDBND& record);
00444 virtual bool parseRecordHYDBND(const char* line, Size size);
00445
00447 virtual bool interpretRecord(const PDB::RecordJRNL& record);
00448 virtual bool fillRecord(const char* line, Size size, PDB::RecordJRNL& record);
00449 virtual bool parseRecordJRNL(const char* line, Size size);
00450
00452 virtual bool interpretRecord(const PDB::RecordKEYWDS& record);
00453 virtual bool fillRecord(const char* line, Size size, PDB::RecordKEYWDS& record);
00454 virtual bool parseRecordKEYWDS(const char* line, Size size);
00455
00457 virtual bool interpretRecord(const PDB::RecordLINK& record);
00458 virtual bool fillRecord(const char* line, Size size, PDB::RecordLINK& record);
00459 virtual bool parseRecordLINK(const char* line, Size size);
00460
00464 virtual bool interpretRecord(const PDB::RecordMASTER& record);
00465 virtual bool fillRecord(const char* line, Size size, PDB::RecordMASTER& record);
00466 virtual bool parseRecordMASTER(const char* line, Size size);
00467
00469 virtual bool interpretRecord(const PDB::RecordMODEL& record);
00470 virtual bool fillRecord(const char* line, Size size, PDB::RecordMODEL& record);
00471 virtual bool parseRecordMODEL(const char* line, Size size);
00472
00474 virtual bool interpretRecord(const PDB::RecordMODRES& record);
00475 virtual bool fillRecord(const char* line, Size size, PDB::RecordMODRES& record);
00476 virtual bool parseRecordMODRES(const char* line, Size size);
00477
00481 virtual bool interpretRecord(const PDB::RecordMTRIX1& record);
00482 virtual bool fillRecord(const char* line, Size size, PDB::RecordMTRIX1& record);
00483 virtual bool parseRecordMTRIX1(const char* line, Size size);
00484
00488 virtual bool interpretRecord(const PDB::RecordMTRIX2& record);
00489 virtual bool fillRecord(const char* line, Size size, PDB::RecordMTRIX2& record);
00490 virtual bool parseRecordMTRIX2(const char* line, Size size);
00491
00495 virtual bool interpretRecord(const PDB::RecordMTRIX3& record);
00496 virtual bool fillRecord(const char* line, Size size, PDB::RecordMTRIX3& record);
00497 virtual bool parseRecordMTRIX3(const char* line, Size size);
00498
00502 virtual bool interpretRecord(const PDB::RecordOBSLTE& record);
00503 virtual bool fillRecord(const char* line, Size size, PDB::RecordOBSLTE& record);
00504 virtual bool parseRecordOBSLTE(const char* line, Size size);
00505
00509 virtual bool interpretRecord(const PDB::RecordORIGX1& record);
00510 virtual bool fillRecord(const char* line, Size size, PDB::RecordORIGX1& record);
00511 virtual bool parseRecordORIGX1(const char* line, Size size);
00512
00516 virtual bool interpretRecord(const PDB::RecordORIGX2& record);
00517 virtual bool fillRecord(const char* line, Size size, PDB::RecordORIGX2& record);
00518 virtual bool parseRecordORIGX2(const char* line, Size size);
00519
00523 virtual bool interpretRecord(const PDB::RecordORIGX3& record);
00524 virtual bool fillRecord(const char* line, Size size, PDB::RecordORIGX3& record);
00525 virtual bool parseRecordORIGX3(const char* line, Size size);
00526
00528 virtual bool interpretRecord(const PDB::RecordREMARK& record);
00529 virtual bool fillRecord(const char* line, Size size, PDB::RecordREMARK& record);
00530 virtual bool parseRecordREMARK(const char* line, Size size);
00531
00533 virtual bool interpretRecord(const PDB::RecordREVDAT& record);
00534 virtual bool fillRecord(const char* line, Size size, PDB::RecordREVDAT& record);
00535 virtual bool parseRecordREVDAT(const char* line, Size size);
00536
00538 virtual bool interpretRecord(const PDB::RecordSCALE1& record);
00539 virtual bool fillRecord(const char* line, Size size, PDB::RecordSCALE1& record);
00540 virtual bool parseRecordSCALE1(const char* line, Size size);
00541
00543 virtual bool interpretRecord(const PDB::RecordSCALE2& record);
00544 virtual bool fillRecord(const char* line, Size size, PDB::RecordSCALE2& record);
00545 virtual bool parseRecordSCALE2(const char* line, Size size);
00546
00548 virtual bool interpretRecord(const PDB::RecordSCALE3& record);
00549 virtual bool fillRecord(const char* line, Size size, PDB::RecordSCALE3& record);
00550 virtual bool parseRecordSCALE3(const char* line, Size size);
00551
00553 virtual bool interpretRecord(const PDB::RecordSEQADV& record);
00554 virtual bool fillRecord(const char* line, Size size, PDB::RecordSEQADV& record);
00555 virtual bool parseRecordSEQADV(const char* line, Size size);
00556
00558 virtual bool interpretRecord(const PDB::RecordSEQRES& record);
00559 virtual bool fillRecord(const char* line, Size size, PDB::RecordSEQRES& record);
00560 virtual bool parseRecordSEQRES(const char* line, Size size);
00561
00563 virtual bool interpretRecord(const PDB::RecordSHEET& record);
00564 virtual bool fillRecord(const char* line, Size size, PDB::RecordSHEET& record);
00565 virtual bool parseRecordSHEET(const char* line, Size size);
00566
00568 virtual bool interpretRecord(const PDB::RecordSIGATM& record);
00569 virtual bool fillRecord(const char* line, Size size, PDB::RecordSIGATM& record);
00570 virtual bool parseRecordSIGATM(const char* line, Size size);
00571
00575 virtual bool interpretRecord(const PDB::RecordSIGUIJ& record);
00576 virtual bool fillRecord(const char* line, Size size, PDB::RecordSIGUIJ& record);
00577 virtual bool parseRecordSIGUIJ(const char* line, Size size);
00578
00580 virtual bool interpretRecord(const PDB::RecordSITE& record);
00581 virtual bool fillRecord(const char* line, Size size, PDB::RecordSITE& record);
00582 virtual bool parseRecordSITE(const char* line, Size size);
00583
00585 virtual bool interpretRecord(const PDB::RecordSLTBRG& record);
00586 virtual bool fillRecord(const char* line, Size size, PDB::RecordSLTBRG& record);
00587 virtual bool parseRecordSLTBRG(const char* line, Size size);
00588
00592 virtual bool interpretRecord(const PDB::RecordSOURCE& record);
00593 virtual bool fillRecord(const char* line, Size size, PDB::RecordSOURCE& record);
00594 virtual bool parseRecordSOURCE(const char* line, Size size);
00595
00597 virtual bool interpretRecord(const PDB::RecordSPRSDE& record);
00598 virtual bool fillRecord(const char* line, Size size, PDB::RecordSPRSDE& record);
00599 virtual bool parseRecordSPRSDE(const char* line, Size size);
00600
00602 virtual bool interpretRecord(const PDB::RecordSSBOND& record);
00603 virtual bool fillRecord(const char* line, Size size, PDB::RecordSSBOND& record);
00604 virtual bool parseRecordSSBOND(const char* line, Size size);
00605
00607 virtual bool interpretRecord(const PDB::RecordTER& record);
00608 virtual bool fillRecord(const char* line, Size size, PDB::RecordTER& record);
00609 virtual bool parseRecordTER(const char* line, Size size);
00610
00612 virtual bool interpretRecord(const PDB::RecordTITLE& record);
00613 virtual bool fillRecord(const char* line, Size size, PDB::RecordTITLE& record);
00614 virtual bool parseRecordTITLE(const char* line, Size size);
00615
00617 virtual bool interpretRecord(const PDB::RecordTURN& record);
00618 virtual bool fillRecord(const char* line, Size size, PDB::RecordTURN& record);
00619 virtual bool parseRecordTURN(const char* line, Size size);
00620
00624 virtual bool interpretRecord(const PDB::RecordTVECT& record);
00625 virtual bool fillRecord(const char* line, Size size, PDB::RecordTVECT& record);
00626 virtual bool parseRecordTVECT(const char* line, Size size);
00628
00630 virtual bool hasFormat();
00631
00632 typedef HashMap<PDB::Integer, PDBAtom*> PDBAtomMap;
00633 typedef Quadruple<String, PDB::Character, PDB::Integer, PDB::AChar> ResidueQuadruple;
00634 typedef HashMap<ResidueQuadruple, Residue*> ResidueMap;
00635 typedef std::list<ResidueQuadruple> QuadrupleList;
00636 typedef std::list<SecondaryStructure*> SecStructList;
00637
00638
00641
00642 PDBFile& operator >> (Protein& protein) throw(Exception::ParseError);
00644 PDBFile& operator >> (Molecule& molecule) throw(Exception::ParseError);
00645
00646 PDBFile& operator >> (System& system) throw(Exception::ParseError);
00648 PDBFile& operator << (const Protein& protein) throw(File::CannotWrite);
00649
00650 PDBFile& operator << (const System& system) throw(File::CannotWrite);
00651
00652 PDBFile& operator << (const Molecule& molecule) throw(File::CannotWrite);
00654 bool read(Protein& protein) throw(Exception::ParseError);
00656 bool read(Molecule& protein) throw(Exception::ParseError);
00658 bool read(System& system) throw(Exception::ParseError);
00660 Molecule* read() throw(Exception::ParseError);
00662 bool write(const Protein& protein) throw(File::CannotWrite);
00664 bool write(const Molecule& molecule) throw(File::CannotWrite);
00666 bool write(const System& system) throw(File::CannotWrite);
00668 bool write(const System& system, const PDBInfo& info) throw(File::CannotWrite);
00670
00671 protected:
00672
00673
00674 PDBFile(const File& pdbf) throw(Exception::FileNotFound);
00675
00676
00677 PDBFile& operator = (const PDBFile& pdbf);
00678
00679
00680
00681
00682 void init_() ;
00683
00684 void postprocessSSBonds_();
00685 void postprocessHelices_();
00686 void postprocessSheetsTurns_(QuadrupleList& sectruct_list, SecStructList& new_secstruct_list);
00687 void postprocessRandomCoils_();
00688
00689
00690
00691
00692
00693
00694 void write_(const AtomContainer& ac, const PDBInfo& info = PDBInfo());
00695
00701 void writeRecord_(PDB::RecordType record, ...);
00702 void writeCONECTRecords_(PDB::Structure::ConectAtomList& cl);
00703
00710 void writeRawRecord_(const char* format, const char* tag, ...);
00711
00713 void addAllRecords_(const PDBInfo& info, PDB::RecordType type);
00714
00716 void writeRecord_(const PDB::RecordSEQRES& seqres);
00718 void writeRecord_(const PDB::RecordHELIX& helix);
00720 void writeRecord_(const PDB::RecordSHEET& helix);
00722 void writeRecord_(const PDB::RecordTURN& helix);
00724 void writeRecord_(const PDB::RecordSSBOND& helix);
00726 void writeRecord_(const PDB::RecordCONECT& helix);
00728 void writeRecord_(const PDB::RecordCRYST1& cryst1);
00730 void writeRecord_(const PDB::RecordMTRIX1& mtrix1);
00732 void writeRecord_(const PDB::RecordMTRIX2& mtrix2);
00734 void writeRecord_(const PDB::RecordMTRIX3& mtrix3);
00735
00736 void writeAtom_(const PDB::Structure::AtomEntry& atom, PDB::AdditionalAtomInfo& cr, bool hetatm = false);
00737
00738 void writeTitleSection_(const PDB::Structure& structure, const PDBInfo& info);
00739 void writePrimaryStructureSection_(const PDB::Structure& structure, const PDBInfo& info);
00740 void writeHeterogenSection_(const PDB::Structure& structure, const PDBInfo& info);
00741 void writeSecondaryStructureSection_(const PDB::Structure& structure, const PDBInfo& info);
00742 void writeConnectivityAnnotationSection_(const PDB::Structure& structure, const PDBInfo& info);
00743 void writeMiscellaneousFeaturesSection_(const PDB::Structure& structure, const PDBInfo& info);
00744 void writeCrystallographicSection_(const PDB::Structure& structure, const PDBInfo& info);
00745 void writeCoordinateSection_(const PDB::Structure& structure, const PDBInfo& info);
00746 void writeConnectivitySection_(const PDB::Structure& structure, const PDBInfo& info);
00747 void writeBookKeepingSection_(const PDB::Structure& structure, const PDBInfo& info);
00748
00749 void writeSEQRESSection_(const std::vector<std::pair<char, String> >& chain_residues);
00750 void writeHELIXSection_(const PDB::Structure& structure);
00751 void writeSHEETSection_(const PDB::Structure& structure);
00752 void writeTURNSection_(const PDB::Structure& structure);
00753 void writeSSBONDSection_(const PDB::Structure& structure);
00754 void writeHYDBNDSection_(const PDB::Structure& structure);
00755 void writeSLTBRGSection_(const PDB::Structure& structure);
00756 void writeCRYST1Section_(const PDB::Structure& structure);
00757 void writeMTRIXnSection_(const PDB::Structure& structure);
00758
00762 static void extractStructure_(const AtomContainer& ac, PDB::Structure& structure);
00763
00767 static bool isHeteroAtom_(const Atom& atom);
00768
00774 static void updateAdditionalAtomInfo_(const PDB::Structure::AtomEntry& atom, PDB::AdditionalAtomInfo& cr);
00775
00776
00777 char line_buffer_[PDB::SIZE_OF_PDB_LINE_BUFFER];
00778
00779 String residue_name_;
00780 Index residue_sequence_number_;
00781 Index current_model_;
00782 Index current_record_;
00783 Size record_fields_;
00784 PDB::RecordType current_record_type_;
00785 PDB::RecordTypeFormat compare_record_type_format_;
00786
00787 PDBAtomMap PDB_atom_map_;
00788 ResidueMap residue_map_;
00789 QuadrupleList ssbond_list_;
00790 QuadrupleList helix_list_;
00791 QuadrupleList sheet_list_;
00792 QuadrupleList turn_list_;
00793
00794 SecStructList new_helix_secstruc_list_;
00795 SecStructList new_sheet_secstruc_list_;
00796 SecStructList new_turn_secstruc_list_;
00797
00798 char alternate_location_indicator_;
00799 PDB::AChar insertion_code_;
00800 PDB::Character chain_ID_;
00801 PDB::Integer sequence_number_;
00802 PDB::AChar code_;
00803 Protein* current_protein_;
00804 const Protein* current_const_protein_;
00805 Chain* current_chain_;
00806 const Chain* current_const_chain_;
00807 Residue* current_residue_;
00808 const Residue* current_const_residue_;
00809 PDBAtom* current_PDB_atom_;
00810 const Atom* current_const_atom_;
00811 String name_;
00812 HashMap<const Atom*, Position> atom_map_;
00813
00815 PDB::BookKeeping book_keeping_;
00816
00818 int verbosity_;
00819
00820 bool strict_line_checking_;
00821
00823 Index selected_model_;
00824
00826 bool store_skipped_records_;
00827
00829 bool ignore_xplor_pseudo_atoms_;
00830
00832 bool parse_partial_charges_;
00833 };
00834
00835
00836
00837
00838
00842 inline
00843 BALL_EXPORT HashIndex Hash(const PDBFile::ResidueQuadruple& quadruple)
00844
00845 {
00846 return (Index)quadruple.third;
00847 }
00848
00852 inline
00853 BALL_EXPORT std::ostream& operator << (std::ostream& s, const Quadruple<String,PDB::Character,PDB::Integer,PDB::AChar>& )
00854 {
00855 return s;
00856 }
00857
00858
00859
00860 # ifndef BALL_NO_INLINE_FUNCTIONS
00861 # include <BALL/FORMAT/PDBFile.iC>
00862 # endif
00863
00864 }
00865
00866 #endif // BALL_FORMAT_PDBFILE_H