#include <PBlock.h>
Public Member Functions | |
PBlock (PResidue *myRes, const string &shellName) | |
PBlock (PResidue *myRes, const string &shellName, const PAtomPositionsSpec &spec) | |
PBlock (PResidue *myRes, const string &shellName, const PAtomPositionsSpec &spec, PBlock *toConnect) | |
PBlock (PResidue *myRes, const string &shellName, PBlock *toConnect) | |
~PBlock () | |
string | getName () const |
string | getType () const |
bool | isOn () const |
PResidue * | getParentResidue () |
int | size () |
PChain * | getChain () const |
void | Detach (const string &blockType) |
void | Reattach () |
bool | InStaticCollision () const |
bool | InSelfCollision () const |
bool | InAnyCollision () const |
pair< PAtom *, PAtom * > | FindStaticCollision () const |
pair< PAtom *, PAtom * > | FindSelfCollision () const |
pair< PAtom *, PAtom * > | FindAnyCollision () const |
AtomCollisions * | getAllCollidingStatic () const |
AtomCollisions * | getAllCollidingSelf () const |
AtomCollisions * | getAllCollidingEither () const |
void | AddAtomsToMap (HASH_MAP_STR(PAtom *)&atomCache) const |
const PSpaceManager * | getSpaceManager () const |
Friends | |
class | PBlockConnection |
class | PBlockReconnector |
PBlock::PBlock | ( | PResidue * | myRes, | |
const string & | shellName | |||
) |
Constructs a new PBlock
as a member of the residue myRes
and with a block shell specified by shellName
. This constructor uses relative coordinates as global positions.
PBlock::PBlock | ( | PResidue * | myRes, | |
const string & | shellName, | |||
const PAtomPositionsSpec & | spec | |||
) |
PBlock::PBlock | ( | PResidue * | myRes, | |
const string & | shellName, | |||
const PAtomPositionsSpec & | spec, | |||
PBlock * | toConnect | |||
) |
Constructs a new PBlock
as a member of the residue myRes
and with a block shell specified by shellName
. This constructor uses the atom positions specified by spec
and connects the new PBlock
to the block toConnect
; it should be called when the block's positions are known, e.g. from a PDB file, but the block must also be connected to an existing block.
Constructs a new PBlock
as a member of the residue myRes
and with a block shell specified by shellName
. This constructor uses the block's default atom positions and connects the new PBlock
to the block toConnect
; it should be called when the block's positions are not known (and thus should be determined randomly) but the block must still be connected to an existing block.
PBlock::~PBlock | ( | ) |
string PBlock::getName | ( | ) | const [inline] |
Returns the block's name, e.g. "TRP".
string PBlock::getType | ( | ) | const [inline] |
Returns the block's type, e.g. "backbone" or "sidechain".
bool PBlock::isOn | ( | ) | const [inline] |
Returns true
if this block is active, false
otherwise.
PResidue* PBlock::getParentResidue | ( | ) | [inline] |
Returns this block's parent residue.
int PBlock::size | ( | ) | [inline] |
Returns the number of atoms within this block.
PChain * PBlock::getChain | ( | ) | const |
Returns this block's parent chain.
void PBlock::Detach | ( | const string & | blockType | ) |
void PBlock::Reattach | ( | ) |
Reattaches this block to its parent chain.
bool PBlock::InStaticCollision | ( | ) | const |
Returns true if any atom in this PBlock
is in static collision, false otherwise.
bool PBlock::InSelfCollision | ( | ) | const |
Returns true if any atom in this PBlock
is in self collision, false otherwise.
bool PBlock::InAnyCollision | ( | ) | const |
Returns true if any atom in this PBlock
is in static or self collision, false otherwise.
Returns a pair of atoms in static collision within this PBlock
, or (NULL, NULL)
if no such atoms exist.
Returns a pair of atoms in self collision within this PBlock
, or (NULL, NULL)
if no such atoms exist.
Returns a pair of atoms in either static or self collision within this PBlock
, or (NULL, NULL)
if no such atoms exist.
AtomCollisions * PBlock::getAllCollidingStatic | ( | ) | const |
Returns a set of all atoms in this PBlock
in static collision.
AtomCollisions * PBlock::getAllCollidingSelf | ( | ) | const |
Returns a set of all atoms in this PBlock
in self collision.
AtomCollisions * PBlock::getAllCollidingEither | ( | ) | const |
Returns a set of all atoms in this PBlock
in either static or self collision.
void PBlock::AddAtomsToMap | ( | HASH_MAP_STR(PAtom *)& | atomCache | ) | const |
Adds all atoms in this PBlock
to the map atomCache
.
const PSpaceManager * PBlock::getSpaceManager | ( | ) | const |
Returns the space manager for the chain this block is in.
friend class PBlockConnection [friend] |
friend class PBlockReconnector [friend] |