00001
00002
00003
00004
00005
00006
00007 #ifndef BALL_KERNEL_SYSTEM_H
00008 #define BALL_KERNEL_SYSTEM_H
00009
00010 #ifndef BALL_KERNEL_ATOM_H
00011 # include <BALL/KERNEL/atomIterator.h>
00012 #endif
00013
00014 #ifndef BALL_KERNEL_MOLECULEITERATOR_H
00015 # include <BALL/KERNEL/moleculeIterator.h>
00016 #endif
00017
00018 #ifndef BALL_KERNEL_PROTEINITERATOR_H
00019 # include <BALL/KERNEL/proteinIterator.h>
00020 #endif
00021
00022 #ifndef BALL_KERNEL_NUCLEICACIDITERATOR_H
00023 # include <BALL/KERNEL/nucleicAcidIterator.h>
00024 #endif
00025
00026 #ifndef BALL_KERNEL_NUCLEOTIDEIDITERATOR_H
00027 # include <BALL/KERNEL/nucleotideIterator.h>
00028 #endif
00029
00030 #define BALL_SYSTEM_DEFAULT_NAME ""
00031
00032 namespace BALL
00033 {
00040 class BALL_EXPORT System
00041 : public AtomContainer
00042 {
00043 public:
00044
00045 BALL_CREATE_DEEP(System)
00046
00047
00050
00052 System();
00053
00055 System(const System& system, bool deep = true);
00056
00058 System(const String& name);
00059
00061 virtual ~System();
00062
00064
00067
00071 void persistentWrite(PersistenceManager& pm, const char* name = 0) const
00072 throw(Exception::GeneralException);
00073
00077 void persistentRead(PersistenceManager& pm)
00078 throw(Exception::GeneralException);
00079
00081
00084
00090 void set(const System& system, bool deep = true);
00091
00096 System& operator = (const System& system);
00097
00102 void get(System& system, bool deep = true) const;
00103
00105
00110 bool operator == (const System& system) const;
00111
00115 bool operator != (const System& system) const;
00116
00120
00126 Molecule* getMolecule(Position position);
00127
00133 const Molecule* getMolecule(Position position) const;
00134
00138 Size countMolecules() const;
00139
00143 Size countFragments() const;
00144
00148 Size countAtoms() const;
00149
00153 Size countProteins() const;
00154
00158 Size countChains() const;
00159
00163 Size countSecondaryStructures() const;
00164
00168 Size countResidues() const;
00169
00173 Size countNucleicAcids() const;
00174
00178 Size countNucleotides() const;
00179
00183 void prepend(Molecule& molecule);
00184
00188 void append(Molecule& molecule);
00189
00193 void insert(Molecule& molecule);
00194
00199 void insertBefore(Molecule& molecule, Composite& before);
00200
00205 void insertAfter(Molecule& molecule, Composite& after);
00206
00210 bool remove(Molecule& molecule);
00211
00216 void spliceBefore(System& system);
00217
00222 void spliceAfter(System& system);
00223
00227 void splice(System& system);
00228
00230
00231
00232
00233 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Atom)
00234 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(AtomContainer)
00235 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Fragment)
00236 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Molecule)
00237 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Protein)
00238 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Residue)
00239 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Chain)
00240 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(SecondaryStructure)
00241 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(Nucleotide)
00242 BALL_KERNEL_DEFINE_ITERATOR_CREATORS(NucleicAcid)
00243
00244 };
00245 }
00246
00247 #endif // BALL_KERNEL_SYSTEM_H