5 #ifndef BALL_FORMAT_PDBFILE_H
6 #define BALL_FORMAT_PDBFILE_H
8 #ifndef BALL_CONCEPT_PROPERTY_H
12 #ifndef BALL_FORMAT_GENERICMOLFILE_H
16 #ifndef BALL_DATATYPE_OPTIONS_H
20 #ifndef BALL_DATATYPE_QUADRUPLE_H
24 #ifndef BALL_FORMAT_PDBDEFS_H
28 #ifndef BALL_FORMAT_PDBINFO_H
32 #ifndef BALL_KERNEL_PDBAtom_H
36 #ifndef BALL_KERNEL_SYSTEM_H
40 #ifndef BALL_KERNEL_RESIDUE_H
44 #ifndef BALL_KERNEL_SECONDARYSTRUCTURE_H
48 #if defined(BALL_HAS_UNORDERED_MAP) || defined(BALL_HAS_HASH_MAP)
49 #ifdef BALL_EXTEND_HASH_IN_STD_NS
53 namespace BALL_MAP_NAMESPACE {
55 struct hash<BALL::Quadruple<BALL::String, BALL::PDB::Character, BALL::PDB::Integer, BALL::PDB::AChar> >
59 {
return (
size_t)f.
third; }
62 #ifdef BALL_EXTEND_HASH_IN_STD_NS
221 virtual void clear(
int state);
224 virtual void clear();
233 virtual float getVersion()
const;
239 void selectModel(
Index index);
252 void selectAltLocationIndicator(
char c);
255 Index getSelectedModel()
const;
258 void selectAllModels();
261 Index getCurrentModel()
const;
264 char* getRecordString();
267 const char* getRecordString()
const;
270 Index getRecordNumber()
const;
278 virtual const char* getAtomElementSymbol
283 virtual const char* getAtomName
287 virtual char getAtomRemotenessIndicator
291 virtual short getAtomBranchDesignator
295 Size countRecordFields()
const;
302 bool from_begin_of_file =
true);
307 (
bool from_begin_of_file =
true);
317 bool parseLine(
const char* line,
Size size,
const char* format_string, ...);
320 bool readLine(
char* line,
Size size,
bool extract_values);
323 bool readFirstRecord(
bool read_values =
true);
326 bool readNextRecord(
bool read_values =
true);
338 virtual bool readUnknownRecord(
const char* line);
342 virtual bool readInvalidRecord(
const char* line);
352 bool skipCurrentRecord();
357 virtual bool parseRecordANISOU(
const char* line,
Size size);
362 virtual bool parseRecordATOM(
const char* line,
Size size);
367 virtual bool parseRecordAUTHOR(
const char* line,
Size size);
372 virtual bool parseRecordCAVEAT(
const char* line,
Size size);
377 virtual bool parseRecordCISPEP(
const char* line,
Size size);
382 virtual bool parseRecordCOMPND(
const char* line,
Size size);
387 virtual bool parseRecordCONECT(
const char* line,
Size size);
394 virtual bool parseRecordCRYST1(
const char* line,
Size size);
399 virtual bool parseRecordDBREF(
const char* line,
Size size);
404 virtual bool parseRecordEND(
const char* line,
Size size);
409 virtual bool parseRecordENDMDL(
const char* line,
Size size);
414 virtual bool parseRecordEXPDTA(
const char* line,
Size size);
421 virtual bool parseRecordFORMUL(
const char* line,
Size size);
426 virtual bool parseRecordFTNOTE(
const char* line,
Size size);
433 virtual bool parseRecordHEADER(
const char* line,
Size size);
438 virtual bool parseRecordHELIX(
const char* line,
Size size);
443 virtual bool parseRecordHET(
const char* line,
Size size);
448 virtual bool parseRecordHETATM(
const char* line,
Size size);
453 virtual bool parseRecordHETNAM(
const char* line,
Size size);
458 virtual bool parseRecordHETSYN(
const char* line,
Size size);
463 virtual bool parseRecordHYDBND(
const char* line,
Size size);
468 virtual bool parseRecordJRNL(
const char* line,
Size size);
473 virtual bool parseRecordKEYWDS(
const char* line,
Size size);
478 virtual bool parseRecordLINK(
const char* line,
Size size);
485 virtual bool parseRecordMASTER(
const char* line,
Size size);
490 virtual bool parseRecordMODEL(
const char* line,
Size size);
495 virtual bool parseRecordMODRES(
const char* line,
Size size);
502 virtual bool parseRecordMTRIX1(
const char* line,
Size size);
509 virtual bool parseRecordMTRIX2(
const char* line,
Size size);
516 virtual bool parseRecordMTRIX3(
const char* line,
Size size);
523 virtual bool parseRecordOBSLTE(
const char* line,
Size size);
530 virtual bool parseRecordORIGX1(
const char* line,
Size size);
537 virtual bool parseRecordORIGX2(
const char* line,
Size size);
544 virtual bool parseRecordORIGX3(
const char* line,
Size size);
549 virtual bool parseRecordREMARK(
const char* line,
Size size);
554 virtual bool parseRecordREVDAT(
const char* line,
Size size);
559 virtual bool parseRecordSCALE1(
const char* line,
Size size);
564 virtual bool parseRecordSCALE2(
const char* line,
Size size);
569 virtual bool parseRecordSCALE3(
const char* line,
Size size);
574 virtual bool parseRecordSEQADV(
const char* line,
Size size);
579 virtual bool parseRecordSEQRES(
const char* line,
Size size);
584 virtual bool parseRecordSHEET(
const char* line,
Size size);
589 virtual bool parseRecordSIGATM(
const char* line,
Size size);
596 virtual bool parseRecordSIGUIJ(
const char* line,
Size size);
601 virtual bool parseRecordSITE(
const char* line,
Size size);
606 virtual bool parseRecordSLTBRG(
const char* line,
Size size);
613 virtual bool parseRecordSOURCE(
const char* line,
Size size);
618 virtual bool parseRecordSPRSDE(
const char* line,
Size size);
623 virtual bool parseRecordSSBOND(
const char* line,
Size size);
628 virtual bool parseRecordTER(
const char* line,
Size size);
633 virtual bool parseRecordTITLE(
const char* line,
Size size);
638 virtual bool parseRecordTURN(
const char* line,
Size size);
645 virtual bool parseRecordTVECT(
const char* line,
Size size);
649 virtual bool hasFormat();
710 bool read(
System& system);
723 bool write(
const Protein& protein);
730 bool write(
const Molecule& molecule);
737 bool write(
const System& system);
760 void postprocessSSBonds_();
761 void postprocessHelices_();
763 void postprocessRandomCoils_();
786 void writeRawRecord_(
const char* format,
const char* tag, ...);
825 void writeSEQRESSection_(
const std::vector<std::pair<char, String> >& chain_residues);
843 static bool isHeteroAtom_(
const Atom& atom);
932 BALL_EXPORT std::ostream& operator << (std::ostream& s, const Quadruple<String,PDB::Character,PDB::Integer,PDB::AChar>& )
939 # ifndef BALL_NO_INLINE_FUNCTIONS
940 # include <BALL/FORMAT/PDBFile.iC>
945 #endif // BALL_FORMAT_PDBFILE_H