BALL::Protein Class Reference
[Molecular Datastructures]

Protein Class. More...

#include <protein.h>

Inheritance diagram for BALL::Protein:
Inheritance graph
[legend]

List of all members.


Public Types

Enums
enum Property { NUMBER_OF_PROPERTIES = Molecule::NUMBER_OF_PROPERTIES }
Properties.

Public Member Functions

bool operator== (const Protein &protein) const
Equality operator.
bool operator!= (const Protein &protein) const
Inequality operator.
Constructors and Destructors
Protein ()
Default constructor.
Protein (const Protein &protein, bool deep=true)
Copy constructor.
Protein (const String &name, const String &id=BALL_PROTEIN_DEFAULT_ID)
Detailled constructor.
virtual ~Protein ()
Destructor.
virtual void clear ()
Clears the contents of the protein.
virtual void destroy ()
Clear the contents of this instance of AtomContainer and removes it from parent composite structures.
Persistence
void persistentWrite (PersistenceManager &pm, const char *name=0) const throw (Exception::GeneralException)
Writes a Protein object to a persistent stream.
void persistentRead (PersistenceManager &pm) throw (Exception::GeneralException)
Reads a Protein object from a persistent stream.
Assignment Methods
void set (const Protein &protein, bool deep=true)
Assignment with cloning facility.
Protein & operator= (const Protein &protein)
Assignment operator.
void get (Protein &protein, bool deep=true) const
Copy this instance to protein .
void swap (Protein &protein)
Swapping of two proteins.
Accessors
Chain * getChain (Position position)
Get a pointer to a child chain at a given position.
const Chain * getChain (Position position) const
Get a pointer to a child chain at a given position.
SecondaryStructure * getSecondaryStructure (Position position)
Get a pointer to a child SecondaryStructure at a given position.
const SecondaryStructure * getSecondaryStructure (Position position) const
Get a pointer to a child SecondaryStructure at a given position.
Residue * getResidue (Position position)
Get a pointer to a child Residue at a given position.
const Residue * getResidue (Position position) const
Get a pointer to a child Residue at a given position.
Residue * getNTerminal ()
Get a pointer to the N-terminal Residue.
const Residue * getNTerminal () const
Get a pointer to the N-terminal Residue.
Residue * getCTerminal ()
Get a pointer to the C-terminal Residue.
const Residue * getCTerminal () const
Get a pointer to the C-terminal Residue.
PDBAtom * getPDBAtom (Position position)
Get a pointer to a child PDB-Atom at a given position.
const PDBAtom * getPDBAtom (Position position) const
Get a pointer to a child PDB-Atom at a given position.
void setID (const String &id)
Set the ID of the NucleicAcid.
const String & getID () const
Retrieve the ID of the NucleicAcid.
Size countChains () const
Count the child chains.
Size countSecondaryStructures () const
Count the child SecondaryStructures.
Size countResidues () const
Count the child Residues.
Size countPDBAtoms () const
Count the child PDB-Atoms.
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.

Detailed Description

Protein Class.

This class is used to represent proteins. A protein may contain several Chain , SecondaryStructure , and Residue .


Member Function Documentation

Size BALL::Protein::countChains ( ) const

Count the child chains.

Returns:
Size the number of chains

Size BALL::Protein::countPDBAtoms ( ) const

Count the child PDB-Atoms.

Returns:
Size the number of PDB-Atoms

Size BALL::Protein::countResidues ( ) const

Count the child Residues.

Returns:
Size the number of Residues

Size BALL::Protein::countSecondaryStructures ( ) const

Count the child SecondaryStructures.

Returns:
Size the number of SecondaryStructures

virtual void BALL::Protein::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::AtomContainer.

virtual void BALL::Protein::dump ( std::ostream & s = std::cout,
Size depth = 0
) const [virtual]

Internal state dump.

Dump the current internal state to the output ostream s with dumping depth depth .

Parameters:
s output stream where to output the internal state
depth the dumping depth

Reimplemented from BALL::Molecule.

void BALL::Protein::get ( Protein & protein,
bool deep = true
) const

Copy this instance to protein .

The assignment is either deep or shallow (default).

Parameters:
protein the Protein to be assigned to

const Chain* BALL::Protein::getChain ( Position position ) const

Get a pointer to a child chain at a given position.

The pointer is 0 if this instance does not have a chain at the given position.

Parameters:
position the position of the child chain
Returns:
Chain* - constant pointer to the child

Chain* BALL::Protein::getChain ( Position position )

Get a pointer to a child chain at a given position.

The pointer is 0 if this instance does not have a chain at the given position.

Parameters:
position the position of the child chain
Returns:
Chain* - mutable pointer to the child

const Residue* BALL::Protein::getCTerminal ( ) const

Get a pointer to the C-terminal Residue.

The pointer is 0 if this instance does not have a Residue with the property "PROPERTY__AMINO_ACID".

Returns:
Residue* - constant pointer to the C-terminal Residue

Residue* BALL::Protein::getCTerminal ( )

Get a pointer to the C-terminal Residue.

The pointer is 0 if this instance does not have a Residue with the property "PROPERTY__AMINO_ACID".

Returns:
Residue* - mutable pointer to the C-terminal Residue

const String& BALL::Protein::getID ( ) const

Retrieve the ID of the NucleicAcid.

Returns:
String the ID

const Residue* BALL::Protein::getNTerminal ( ) const

Get a pointer to the N-terminal Residue.

The pointer is 0 if this instance does not have a Residue with the property "PROPERTY__AMINO_ACID".

Returns:
Residue* - constant pointer to the N-terminal Residue

Residue* BALL::Protein::getNTerminal ( )

Get a pointer to the N-terminal Residue.

The pointer is 0 if this instance does not have a Residue with the property "PROPERTY__AMINO_ACID".

Returns:
Residue* - mutable pointer to the N-terminal Residue

const PDBAtom* BALL::Protein::getPDBAtom ( Position position ) const

Get a pointer to a child PDB-Atom at a given position.

The pointer is 0 if this instance does not have a PDB-Atom at the given position.

Parameters:
position the position of the child PDB-Atom
Returns:
Residue* - constant pointer to the child

PDBAtom* BALL::Protein::getPDBAtom ( Position position )

Get a pointer to a child PDB-Atom at a given position.

The pointer is 0 if this instance does not have a PDB-Atom at the given position.

Parameters:
position the position of the child PDB-Atom
Returns:
Residue* - mutable pointer to the child

const Residue* BALL::Protein::getResidue ( Position position ) const

Get a pointer to a child Residue at a given position.

The pointer is 0 if this instance does not have a Residue at the given position.

Parameters:
position the position of the child Residue
Returns:
Residue* - constant pointer to the child

Residue* BALL::Protein::getResidue ( Position position )

Get a pointer to a child Residue at a given position.

The pointer is 0 if this instance does not have a Residue at the given position.

Parameters:
position the position of the child Residue
Returns:
Residue* - mutable pointer to the child

const SecondaryStructure* BALL::Protein::getSecondaryStructure ( Position position ) const

Get a pointer to a child SecondaryStructure at a given position.

The pointer is 0 if this instance does not have a SecondaryStructure at the given position.

Parameters:
position the position of the child SecondaryStructure
Returns:
SecondaryStructure* - constant pointer to the child

SecondaryStructure* BALL::Protein::getSecondaryStructure ( Position position )

Get a pointer to a child SecondaryStructure at a given position.

The pointer is 0 if this instance does not have a SecondaryStructure at the given position.

Parameters:
position the position of the child SecondaryStructure
Returns:
SecondaryStructure* - mutable pointer to the child

virtual bool BALL::Protein::isValid ( ) const [virtual]

Internal state and consistency self-validation.

Returns:
bool -true if the internal state of this instance is correct (self-validated) and consistent, false otherwise

Reimplemented from BALL::AtomContainer.

bool BALL::Protein::operator!= ( const Protein & protein ) const

Inequality operator.

See also:
operator ==

Protein& BALL::Protein::operator= ( const Protein & protein )

Assignment operator.

Parameters:
protein the Protein to be copied (cloned)
Returns:
Protein& - this instance

bool BALL::Protein::operator== ( const Protein & protein ) const

Equality operator.

Two proteins are equal if they have the same handle.

See also:
Object::operator ==.

void BALL::Protein::persistentRead ( PersistenceManager & pm ) throw (Exception::GeneralException) [virtual]

Reads a Protein object from a persistent stream.

Parameters:
pm the persistence manager

Reimplemented from BALL::Molecule.

void BALL::Protein::persistentWrite ( PersistenceManager & pm,
const char * name = 0
) const throw (Exception::GeneralException) [virtual]

Writes a Protein object to a persistent stream.

Parameters:
pm the persistence manager

Reimplemented from BALL::Molecule.

void BALL::Protein::set ( const Protein & protein,
bool deep = true
)

Assignment with cloning facility.

The assignment is either deep or shallow (default).

Parameters:
protein the Protein to be copied (cloned)
deep make a deep (=true) or shallow (=false) copy

void BALL::Protein::setID ( const String & id )

Set the ID of the NucleicAcid.

Parameters:
id the new ID

void BALL::Protein::swap ( Protein & protein )

Swapping of two proteins.

Parameters:
protein to swap with this instance

Generated on Thu Aug 6 18:30:32 2009 for BALL by doxygen 1.5.8