#include <atomContainer.h>

Public Types |
|
|
Enums
|
|
| enum | Property { NUMBER_OF_PROPERTIES = 0 } |
| The number of predefined properties
for AtomContainer. |
|
Public Member Functions |
|
|
Constructors and Destructors
|
|
| AtomContainer () | |
| Default constructor. |
|
| AtomContainer (const AtomContainer &atom_container, bool deep=true) | |
| Copy constructor. |
|
| AtomContainer (const String &name) | |
| Detailed Constructor. |
|
| virtual | ~AtomContainer () |
| Destructor. |
|
| virtual void | clear () |
| Clear the contents of this instance
of AtomContainer.
|
|
| virtual void | destroy () |
| Clear the contents of this instance
of AtomContainer and
removes it from parent composite structures. |
|
|
Persistence
|
|
| virtual void | persistentWrite (PersistenceManager &pm, const char *name=0) const throw (Exception::GeneralException) |
| Write an AtomContainer object to a
persistent stream. |
|
| virtual void | persistentRead (PersistenceManager &pm) throw (Exception::GeneralException) |
| Read an AtomContainer object from
a persistent stream. |
|
|
Assignment
|
|
| void | set (const AtomContainer &atom_container, bool deep=true) |
| Assign the contents of an AtomContainer The
assignment is either deep or shallow (default is deep).
|
|
| AtomContainer & | operator= (const AtomContainer &atom_container) |
| Assignment operator. |
|
| void | get (AtomContainer &atom_container, bool deep=true) const |
| Copy to another instance of
AtomContainer. |
|
| void | swap (AtomContainer &atom_container) |
| Swap the contents of two
AtomContainers. |
|
|
Predicates
|
|
| bool | operator== (const AtomContainer &atom_container) const |
| Equality operator. |
|
| bool | operator!= (const AtomContainer &atom_container) const |
| Inequality operator. |
|
|
Accessors
|
|
| void | setName (const String &name) |
| Set the name. |
|
| const String & | getName () const |
| Return the name. |
|
| AtomContainer * | getSuperAtomContainer () |
| Get a mutable pointer to the parent
AtomContainer. |
|
| const AtomContainer * | getSuperAtomContainer () const |
| Get a constant pointer to the parent
AtomContainer. |
|
| AtomContainer * | getAtomContainer (Position position) |
| Get a pointer to a child AtomContainer at a given
position. |
|
| const AtomContainer * | getAtomContainer (Position position) const |
| Get a constant pointer to a child
AtomContainer at a given
position. |
|
| Atom * | getAtom (Position position) |
| Get a pointer to a child atom at a
given position. |
|
| const Atom * | getAtom (Position position) const |
| Get a pointer to a child atom at a
given position. |
|
| Atom * | getAtom (const String &name) |
| Get a pointer to a child atom with
the name name . |
|
| const Atom * | getAtom (const String &name) const |
| Get a pointer to a child atom with
the name name . |
|
| Size | countAtomContainers () const |
| Count the child AtomContainers.
|
|
| Size | countAtoms () const |
| Count the child atoms. |
|
| Size | countBonds () const |
| Count the child bonds. |
|
| Size | countInterBonds () const |
| Count all bonds which connect atoms
in this instance with atoms outside. |
|
| Size | countIntraBonds () const |
| Count all bonds which connect 2
atoms in this instance. |
|
| void | prepend (Atom &atom) |
| Prepend an atom at position 0.
|
|
| void | append (Atom &atom) |
| Append an atom to the last position.
|
|
| void | insert (Atom &atom) |
| Insert an atom to the last position.
|
|
| void | insertBefore (Atom &atom, Composite &before) |
| Insert an atom before a given
Composite object. |
|
| void | insertAfter (Atom &atom, Composite &after) |
| Insert an atom after a given
Composite object. |
|
| bool | remove (Atom &atom) |
| Remove an atom. |
|
| Size | removeHavingProperty (BALL::Property p) |
| Size | removeNotHavingProperty (BALL::Property p) |
| Size | removeHavingProperty (const string &name) |
| Size | removeNotHavingProperty (const string &name) |
| void | prepend (AtomContainer &atom_container) |
| Prepend an AtomContainer at position
0. |
|
| void | append (AtomContainer &atom_container) |
| Append an AtomContainer at the last
position. |
|
| void | insert (AtomContainer &atom_container) |
| Insert an AtomContainer at the last
position. |
|
| void | insertBefore (AtomContainer &atom_container, Composite &before) |
| Insert an AtomContainer before a
given Composite object. |
|
| void | insertAfter (AtomContainer &atom_container, Composite &after) |
| Insert an AtomContainer after a
given Composite object. |
|
| void | spliceBefore (AtomContainer &atom_container) |
Cut all children of
atom_container and prepend them before the
children of this instance. |
|
| void | spliceAfter (AtomContainer &atom_container) |
Cut all children of
atom_container and append them after the
children of this instance. |
|
| void | splice (AtomContainer &atom_container) |
| Move the children of
{atom_container} into this instance. |
|
| bool | remove (AtomContainer &atom_container) |
| Remove an AtomContainer. |
|
|
Miscellaneous
|
|
| void | destroyBonds () |
| Destroy all bonds in this
instance. |
|
|
Predicates
|
|
| bool | isSubAtomContainerOf (const AtomContainer &atom_container) const |
| Test if an AtomContainer is a child.
|
|
| bool | isSuperAtomContainerOf (const AtomContainer &atom_container) const |
| Test if an AtomContainer is the
parent. |
|
| virtual bool | isValid () const |
| Debugging and Diagnostics. |
|
| virtual void | dump (std::ostream &s=std::cout, Size depth=0) const |
| Internal state dump. |
|
|
Internal Iteration
|
|
| bool | applyIntraBond (UnaryProcessor< Bond > &processor) |
| Apply to all bonds connecting two
atoms inside this AtomContainer. |
|
| bool | applyInterBond (UnaryProcessor< Bond > &processor) |
| Apply to all bonds connected to
atoms outside this AtomContainer. |
|
The AtomContainer class is
the base class of all kernel classes containing atoms.
| BALL::AtomContainer::AtomContainer | ( | const AtomContainer & | atom_container, | |
| bool | deep =
true |
|||
| ) |
Copy constructor.
| atom_container | the AtomContainer to construct from | |
| deep | a flag indicating cloning |
| BALL::AtomContainer::AtomContainer | ( | const String & | name | ) |
Detailed Constructor.
| name | the name of the AtomContainer |
| void BALL::AtomContainer::append | ( | AtomContainer & | atom_container | ) |
Append an AtomContainer at the last position.
| atom_container | the AtomContainer to prepend |
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::append | ( | Atom & | atom | ) |
Append an atom to the last position.
| atom | the atom to append |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| virtual void BALL::AtomContainer::clear | ( | ) | [virtual] |
Clear the contents of this instance of AtomContainer.
This methods clears the base fragment's name, destroys all its children (as in Composite::clear ), but does not remove it from its parent composite structures.
Reimplemented from BALL::Composite.
Reimplemented in BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, and BALL::SecondaryStructure.
| Size BALL::AtomContainer::countAtomContainers | ( | ) | const |
Count the child AtomContainers.
| Size BALL::AtomContainer::countAtoms | ( | ) | const |
| Size BALL::AtomContainer::countBonds | ( | ) | const |
Count the child bonds.
| Size BALL::AtomContainer::countInterBonds | ( | ) | const |
Count all bonds which connect atoms in this instance with atoms outside.
| Size BALL::AtomContainer::countIntraBonds | ( | ) | const |
Count all bonds which connect 2 atoms in this instance.
| virtual void BALL::AtomContainer::destroy | ( | ) | [virtual] |
Clear the contents of this instance of AtomContainer and removes it from parent composite structures.
This methods clears the base fragment's name, destroys all its children (as in Composite::destroy ), and removes it from its parent composite structures.
Reimplemented from BALL::Composite.
Reimplemented in BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, and BALL::SecondaryStructure.
| virtual void BALL::AtomContainer::dump | ( | std::ostream & | s =
std::cout, |
|
| Size | depth =
0 |
|||
| ) | const [virtual] |
Internal state dump.
Dump the current internal state of this instance to the output ostream s with dumping depth depth .
| s | - output stream where to output the internal state of this instance | |
| depth | - the dumping depth |
Reimplemented from BALL::Composite.
Reimplemented in BALL::Chain, BALL::Fragment, BALL::Molecule, BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, and BALL::SecondaryStructure.
| void BALL::AtomContainer::get | ( | AtomContainer & | atom_container, | |
| bool | deep =
true |
|||
| ) | const |
Copy to another instance of AtomContainer.
The assignment is either deep or shallow (default is deep).
| atom_container | the AtomContainer to be assigned to |
Get a pointer to a child atom with the name name .
The pointer is 0 if this instance AtomContainer does not have an atom with this name.
| name | the name of the child atom |
Get a pointer to a child atom with the name name .
The pointer is 0 if this instance does not have an atom with this name.
| name | the name of the child atom |
| const Atom* BALL::AtomContainer::getAtom | ( | Position | position | ) | const |
Get a pointer to a child atom at a given position.
The pointer is 0 if this instance does not have an atom at the given position.
| position | the position of the child atom |
| Atom* BALL::AtomContainer::getAtom | ( | Position | position | ) |
Get a pointer to a child atom at a given position.
The pointer is 0 if this instance does not have an atom at the given position.
| position | the position of the child atom |
| const AtomContainer* BALL::AtomContainer::getAtomContainer | ( | Position | position | ) | const |
Get a constant pointer to a child AtomContainer at a given position.
The pointer is 0 if this instance does not have an AtomContainer at the given position.
| position | of the child AtomContainer |
| AtomContainer* BALL::AtomContainer::getAtomContainer | ( | Position | position | ) |
Get a pointer to a child AtomContainer at a given position.
The pointer is 0 if this instance does not have an AtomContainer at the given position.
| position | of the child AtomContainer |
| const String& BALL::AtomContainer::getName | ( | ) | const |
Return the name.
| const AtomContainer* BALL::AtomContainer::getSuperAtomContainer | ( | ) | const |
Get a constant pointer to the parent AtomContainer.
The pointer is 0 if this instance does not have a parent AtomContainer.
Reimplemented in BALL::Molecule.
| AtomContainer* BALL::AtomContainer::getSuperAtomContainer | ( | ) |
Get a mutable pointer to the parent AtomContainer.
The pointer is 0 if this instance does not have a parent AtomContainer.
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::insert | ( | AtomContainer & | atom_container | ) |
Insert an AtomContainer at the last position.
| atom_container | the AtomContainer to insert |
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::insert | ( | Atom & | atom | ) |
Insert an atom to the last position.
| atom | the atom to insert |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| void BALL::AtomContainer::insertAfter | ( | AtomContainer & | atom_container, | |
| Composite & | after | |||
| ) |
Insert an AtomContainer after a given Composite object.
| atom_container | the AtomContainer to insert | |
| after | the Composite object to insert after |
Reimplemented in BALL::Molecule.
Insert an atom after a given Composite object.
| atom | the atom to insert | |
| after | the Composite object to insert after |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| void BALL::AtomContainer::insertBefore | ( | AtomContainer & | atom_container, | |
| Composite & | before | |||
| ) |
Insert an AtomContainer before a given Composite object.
| atom_container | the AtomContainer to insert | |
| before | the Composite object to insert before |
Reimplemented in BALL::Molecule.
Insert an atom before a given Composite object.
| atom | the atom to insert | |
| before | the Composite object to insert before |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| bool BALL::AtomContainer::isSubAtomContainerOf | ( | const AtomContainer & | atom_container | ) | const |
Test if an AtomContainer is a child.
| atom_container | the AtomContainer to test |
Reimplemented in BALL::Molecule.
| bool BALL::AtomContainer::isSuperAtomContainerOf | ( | const AtomContainer & | atom_container | ) | const |
Test if an AtomContainer is the parent.
| atom_container | the AtomContainer to test |
| virtual bool BALL::AtomContainer::isValid | ( | ) | const [virtual] |
Debugging and Diagnostics.
Internal state and consistency self-validation. If the
internal state of this instance is correct (self-validated)
and consistent true is returned,
false otherwise.
Reimplemented from BALL::Composite.
Reimplemented in BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, and BALL::SecondaryStructure.
| bool BALL::AtomContainer::operator!= | ( | const AtomContainer & | atom_container | ) | const |
Inequality operator.
| AtomContainer& BALL::AtomContainer::operator= | ( | const AtomContainer & | atom_container | ) |
Assignment operator.
The assignment is deep.
| atom_container | the AtomContainer to be copied (cloned) |
| bool BALL::AtomContainer::operator== | ( | const AtomContainer & | atom_container | ) | const |
Equality operator.
Two instances of AtomContainer are equal if they have the same handle.
| virtual void BALL::AtomContainer::persistentRead | ( | PersistenceManager & | pm | ) | throw (Exception::GeneralException)
[virtual] |
Read an AtomContainer object from a persistent stream.
| pm | the persistence manager |
Reimplemented from BALL::Composite.
Reimplemented in BALL::Chain, BALL::Fragment, BALL::Molecule, BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, BALL::SecondaryStructure, and BALL::System.
| virtual void BALL::AtomContainer::persistentWrite | ( | PersistenceManager & | pm, | |
| const char * | name =
0 |
|||
| ) | const throw (Exception::GeneralException)
[virtual] |
Write an AtomContainer object to a persistent stream.
| pm | the persistence manager |
Reimplemented from BALL::Composite.
Reimplemented in BALL::Chain, BALL::Fragment, BALL::Molecule, BALL::NucleicAcid, BALL::Nucleotide, BALL::Protein, BALL::Residue, BALL::SecondaryStructure, and BALL::System.
| void BALL::AtomContainer::prepend | ( | AtomContainer & | atom_container | ) |
Prepend an AtomContainer at position 0.
| atom_container | the AtomContainer to prepend |
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::prepend | ( | Atom & | atom | ) |
Prepend an atom at position 0.
| atom | the atom to prepend |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| bool BALL::AtomContainer::remove | ( | AtomContainer & | atom_container | ) |
Remove an AtomContainer.
| atom_container | the AtomContainer to remove |
Reimplemented in BALL::Molecule.
| bool BALL::AtomContainer::remove | ( | Atom & | atom | ) |
Remove an atom.
| atom | the atom to remove |
Reimplemented in BALL::Molecule, and BALL::Nucleotide.
| void BALL::AtomContainer::set | ( | const AtomContainer & | atom_container, | |
| bool | deep =
true |
|||
| ) |
Assign the contents of an AtomContainer The assignment is either deep or shallow (default is deep).
| atom_container | the atom_container to be copied (cloned) | |
| deep | make a deep (=true) or shallow
(=false) copy |
| void BALL::AtomContainer::setName | ( | const String & | name | ) |
Set the name.
| name | the new name |
| void BALL::AtomContainer::splice | ( | AtomContainer & | atom_container | ) |
Move the children of {atom_container} into this instance.
The children of atom_container are inserted
at its position if it is is a child of this.
Otherwise the children are inserted using spliceBefore .
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::spliceAfter | ( | AtomContainer & | atom_container | ) |
Cut all children of atom_container and
append them after the children of this instance.
| atom_container | the AtomContainer to access |
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::spliceBefore | ( | AtomContainer & | atom_container | ) |
Cut all children of atom_container and
prepend them before the children of this instance.
| atom_container | the AtomContainer to access |
Reimplemented in BALL::Molecule.
| void BALL::AtomContainer::swap | ( | AtomContainer & | atom_container | ) |
Swap the contents of two AtomContainers.
| atom_container | the AtomContainer this instance is being swapped with. |
1.5.8