#include <nucleicAcid.h>
Public Types |
|
Enums
|
|
enum | Property { NUMBER_OF_PROPERTIES = Molecule::NUMBER_OF_PROPERTIES } |
Properties. |
|
Public Member Functions |
|
bool | operator== (const NucleicAcid &nucleic_acid) const |
Equality operator. |
|
bool | operator!= (const NucleicAcid &nucleic_acid) const |
Inequality operator. |
|
Constructors and Destructors
|
|
NucleicAcid () | |
Default constructor. |
|
NucleicAcid (const NucleicAcid &nucleic_acid, bool deep=true) | |
Copy constructor. |
|
NucleicAcid (const String &name, const String &id=BALL_NUCLEICACID_DEFAULT_ID) | |
Detailed constructor. |
|
virtual | ~NucleicAcid () |
Destructor. |
|
virtual void | clear () |
Clear the contents of the nucleic
acid. |
|
virtual void | destroy () |
Clear the contents of the nucleic
acid and remove it from parent kernel objects. |
|
Persistence
|
|
void | persistentWrite (PersistenceManager &pm, const char *name=0) const throw (Exception::GeneralException) |
Writes a NucleicAcid object to a
persistent stream. |
|
void | persistentRead (PersistenceManager &pm) throw (Exception::GeneralException) |
Reads a NucleicAcid object from a
persistent stream. |
|
Assignment Methods
|
|
void | set (const NucleicAcid &nucleic_acid, bool deep=true) |
Assignment with cloning facility.
|
|
NucleicAcid & | operator= (const NucleicAcid &nucleic_acid) |
Assignment operator. |
|
void | get (NucleicAcid &nucleic_acid, bool deep=true) const |
Assign a NucleicAcid object from
another. |
|
void | swap (NucleicAcid &nucleic_acid) |
Swap the contents of two NucleicAcid objects. |
|
Accessors
|
|
Nucleotide * | getNucleotide (Position position) |
Get a pointer to a child Nucleotide at a given position.
|
|
const Nucleotide * | getNucleotide (Position position) const |
Get a pointer to a child Nucleotide at a given position.
|
|
Nucleotide * | get3Prime () |
Retrieve a pointer to the Nucleotide at the 3'-end of this
instance. |
|
const Nucleotide * | get3Prime () const |
Retrieve a const pointer to the
nucleotide at the 3'-end of this instance. |
|
Nucleotide * | get5Prime () |
Retrieve a pointer to the Nucleotide at the 5'-end of this
instance. |
|
const Nucleotide * | get5Prime () const |
Retrieve a const pointer to the
Nucleotide at the 5'-end of this
instance. |
|
void | setID (const String &id) |
Set the ID of the NucleicAcid. |
|
const String & | getID () const |
Retrieve the ID of the NucleicAcid. |
|
Size | countNucleotides () const |
Return the number of Nucleotides
contained in this instance NucleicAcid. |
|
Debugging and Diagnostics
|
|
virtual bool | isValid () const |
Internal state and consistency
self-validation. |
|
virtual void | dump (std::ostream &s=std::cout, Size depth=0) const |
Internal state dump. |
Size BALL::NucleicAcid::countNucleotides | ( | ) | const |
Return the number of Nucleotides contained in this instance NucleicAcid.
virtual void BALL::NucleicAcid::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::Molecule.
const Nucleotide* BALL::NucleicAcid::get3Prime | ( | ) | const |
Retrieve a const pointer to the nucleotide at the 3'-end of this instance.
The pointer is 0 if this instance does not have a Nucleotide.
Nucleotide* BALL::NucleicAcid::get3Prime | ( | ) |
Retrieve a pointer to the Nucleotide at the 3'-end of this instance.
The pointer is 0 if this instance does not have a Nucleotide.
const Nucleotide* BALL::NucleicAcid::get5Prime | ( | ) | const |
Retrieve a const pointer to the Nucleotide at the 5'-end of this instance.
The pointer is 0 if this instance does not have a Nucleotide.
Nucleotide* BALL::NucleicAcid::get5Prime | ( | ) |
Retrieve a pointer to the Nucleotide at the 5'-end of this instance.
The pointer is 0 if this instance does not have a Nucleotide.
const String& BALL::NucleicAcid::getID | ( | ) | const |
Retrieve the ID of the NucleicAcid.
const Nucleotide* BALL::NucleicAcid::getNucleotide | ( | Position | position | ) | const |
Get a pointer to a child Nucleotide at a given position.
The pointer is 0 if this instance does not have a Nucleotide at the given position.
position | the position of the child Nucleotide |
Nucleotide* BALL::NucleicAcid::getNucleotide | ( | Position | position | ) |
Get a pointer to a child Nucleotide at a given position.
The pointer is 0 if this instance does not have a Nucleotide at the given position.
position | the position of the child Nucleotide |
virtual bool BALL::NucleicAcid::isValid | ( | ) | const [virtual] |
Internal state and consistency self-validation.
true
if the internal state of
this instance atom is correct (self-validated) and
consistent, false
otherwiseReimplemented from BALL::AtomContainer.
bool BALL::NucleicAcid::operator!= | ( | const NucleicAcid & | nucleic_acid | ) | const |
Inequality operator.
bool BALL::NucleicAcid::operator== | ( | const NucleicAcid & | nucleic_acid | ) | const |
Equality operator.
Two nucleic acids are equal if they have the same handle.
void BALL::NucleicAcid::persistentRead | ( | PersistenceManager & | pm | ) | throw (Exception::GeneralException)
[virtual] |
Reads a NucleicAcid object from a persistent stream.
pm | the persistence manager |
Reimplemented from BALL::Molecule.
void BALL::NucleicAcid::persistentWrite | ( | PersistenceManager & | pm, | |
const char * | name =
0 |
|||
) | const throw (Exception::GeneralException)
[virtual] |
Writes a NucleicAcid object to a persistent stream.
pm | the persistence manager |
Reimplemented from BALL::Molecule.
void BALL::NucleicAcid::set | ( | const NucleicAcid & | nucleic_acid, | |
bool | deep =
true |
|||
) |
Assignment with cloning facility.
The assignment is either deep or shallow (default).
nucleic_acid | the NucleicAcid to be copied (cloned) | |
deep | make a deep (=true ) or shallow
(=false ) copy |
void BALL::NucleicAcid::setID | ( | const String & | id | ) |
Set the ID of the NucleicAcid.
id | the new ID |