Main Page | Modules | Namespace List | Class Hierarchy | Class List | Namespace Members | Class Members

Selectable Class Reference
[Miscellaneous]

Selectable Concept. More...

#include <selectable.h>

Inheritance diagram for Selectable:

Composite Atom AtomContainer Bond PDBAtom Chain Fragment Molecule SecondaryStructure System Nucleotide Residue NucleicAcid Protein List of all members.

Public Member Functions

Constructors and Destructors
 Selectable () throw ()
 Default Constructor.
 Selectable (const Selectable &selectable, bool deep=true) throw ()
 Copy constructor.
virtual ~Selectable () throw ()
 Destructor.
virtual void clear () throw ()
 Clear the selection flag.
Assignment
void set (const Selectable &selectable, bool deep=true) throw ()
 Assign the contents of another selectable object to this object.
const Selectableoperator= (const Selectable &selectable) throw ()
 Assignment operator.
void get (Selectable &selectable, bool deep=true) const throw ()
 Copy the contents of this object into another.
void swap (Selectable &selectable) throw ()
 Swap the contents of two objects.
virtual void select () throw ()
 Select the object.
virtual void deselect () throw ()
 Deselect the object.
virtual void setSelected (bool selected) throw ()
 For faster access.
Predicates
bool isSelected () const throw ()
 Get the object state.
bool operator== (const Selectable &selectable) const throw ()
 Equality operator.
bool operator!= (const Selectable &selectable) const throw ()
 Inequality operator.
Storable interface.
void write (PersistenceManager &pm) const throw ()
 Persistent stream writing.
bool read (PersistenceManager &pm) throw ()
 Persistent stream reading.
Debugging and Diagnostics
virtual void dump (::std::ostream &s=std::cout, Size depth=0) const throw ()

Protected Attributes

bool selected_

Detailed Description

Selectable Concept.

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.

Interface: Storable


Constructor & Destructor Documentation

Selectable::Selectable  )  throw ()
 

Default Constructor.

Creates a new selectable object and sets its state to unselected.

Selectable::Selectable const Selectable selectable,
bool  deep = true
throw ()
 

Copy constructor.

Creates a copy of selectable object.

Parameters:
selectable the Selectable object to be copied
deep ignored

virtual Selectable::~Selectable  )  throw () [virtual]
 

Destructor.

The destructor has no functionality.


Member Function Documentation

virtual void Selectable::clear  )  throw () [virtual]
 

Clear the selection flag.

Clear resets the selection flag to unselected.

Reimplemented in Composite, Atom, AtomContainer, Bond, NucleicAcid, Nucleotide, PDBAtom, Protein, Residue, and SecondaryStructure.

virtual void Selectable::deselect  )  throw () [virtual]
 

Deselect the object.

The internal flag is set to false.

Reimplemented in Composite.

void Selectable::get Selectable selectable,
bool  deep = true
const throw ()
 

Copy the contents of this object into another.

Parameters:
selectable the object to be assigned to
deep ignored

bool Selectable::isSelected  )  const throw ()
 

Get the object state.

Returns:
bool true, if the object is selected, false otherwise

const Selectable& Selectable::operator= const Selectable selectable  )  throw ()
 

Assignment operator.

Assigns the contents of another Selectable object to this object.

Parameters:
selectable the object to be copied

bool Selectable::read PersistenceManager pm  )  throw ()
 

Persistent stream reading.

This method reads a boolean variable from the persistent stream using the readPrimitive method of the PersistenceManager.

Parameters:
pm the persistence manager

virtual void Selectable::select  )  throw () [virtual]
 

Select the object.

The internal flag is set to true.

Reimplemented in Composite.

void Selectable::set const Selectable selectable,
bool  deep = true
throw ()
 

Assign the contents of another selectable object to this object.

Parameters:
selectable the object whose contents are to be copied
deep ignored

void Selectable::swap Selectable selectable  )  throw ()
 

Swap the contents of two objects.

Parameters:
selectable the object to swap contents with

void Selectable::write PersistenceManager pm  )  const throw ()
 

Persistent stream writing.

This method writes a boolean variable to the persistent stream using the writePrimitive method of the PersistenceManager.

Parameters:
pm the persistence manager