#include <selectable.h>
Public Member Functions |
|
Constructors and Destructors
|
|
Selectable () | |
Default Constructor. |
|
Selectable (const Selectable &selectable, bool deep=true) | |
Copy constructor. |
|
virtual | ~Selectable () |
Destructor. |
|
virtual void | clear () |
Clear the selection flag. |
|
Assignment
|
|
void | set (const Selectable &selectable, bool deep=true) |
Assign the contents of another
selectable object to this object. |
|
const Selectable & | operator= (const Selectable &selectable) |
Assignment operator. |
|
void | get (Selectable &selectable, bool deep=true) const |
Copy the contents of this object
into another. |
|
void | swap (Selectable &selectable) |
Swap the contents of two objects.
|
|
virtual void | select () |
Accessors. |
|
virtual void | deselect () |
Deselect the object. |
|
virtual void | setSelected (bool selected) |
For faster access. |
|
Predicates
|
|
bool | isSelected () const |
Get the object state. |
|
bool | operator== (const Selectable &selectable) const |
Equality operator. |
|
bool | operator!= (const Selectable &selectable) const |
Inequality operator. |
|
Storable interface.
|
|
void | write (PersistenceManager &pm) const |
Persistent stream writing. |
|
bool | read (PersistenceManager &pm) |
Persistent stream reading. |
|
Debugging and Diagnostics
|
|
virtual void | dump (::std::ostream &s=std::cout, Size depth=0) const |
Protected Attributes |
|
bool | selected_ |
Selectable implements the ability of objects to be selected. It is used in the BALL kernel to mark parts of the kernel objects for special operations. In principle, Selectable provides a boolean flag and defines an interface to access this flag.
BALL::Selectable::Selectable | ( | ) |
Default Constructor.
Creates a new selectable object and sets its state to unselected.
BALL::Selectable::Selectable | ( | const Selectable & | selectable, | |
bool | deep =
true |
|||
) |
Copy constructor.
Creates a copy of selectable object.
selectable | the Selectable object to be copied | |
deep | ignored |
virtual BALL::Selectable::~Selectable | ( | ) | [virtual] |
Destructor.
The destructor has no functionality.
virtual void BALL::Selectable::clear | ( | ) | [virtual] |
Clear the selection flag.
Clear resets the selection flag to unselected.
Reimplemented in BALL::Composite, BALL::Atom, BALL::AtomContainer, BALL::Bond, BALL::NucleicAcid, BALL::Nucleotide, BALL::PDBAtom, BALL::Protein, BALL::Residue, and BALL::SecondaryStructure.
virtual void BALL::Selectable::deselect | ( | ) | [virtual] |
void BALL::Selectable::get | ( | Selectable & | selectable, | |
bool | deep =
true |
|||
) | const |
Copy the contents of this object into another.
selectable | the object to be assigned to | |
deep | ignored |
bool BALL::Selectable::isSelected | ( | ) | const |
Get the object state.
Referenced by BALL::MolmecSupport::computeTorsions().
const Selectable& BALL::Selectable::operator= | ( | const Selectable & | selectable | ) |
Assignment operator.
Assigns the contents of another Selectable object to this object.
selectable | the object to be copied |
bool BALL::Selectable::read | ( | PersistenceManager & | pm | ) |
Persistent stream reading.
This method reads a boolean variable from the persistent
stream using the readPrimitive
method of the
PersistenceManager.
pm | the persistence manager |
virtual void BALL::Selectable::select | ( | ) | [virtual] |
void BALL::Selectable::set | ( | const Selectable & | selectable, | |
bool | deep =
true |
|||
) |
Assign the contents of another selectable object to this object.
selectable | the object whose contents are to be copied | |
deep | ignored |
void BALL::Selectable::swap | ( | Selectable & | selectable | ) |
Swap the contents of two objects.
selectable | the object to swap contents with |
void BALL::Selectable::write | ( | PersistenceManager & | pm | ) | const |
Persistent stream writing.
This method writes a boolean variable to the persistent
stream using the writePrimitive
method of the
PersistenceManager.
pm | the persistence manager |