|
OpenStructure
|
#include <residue_view.hh>
Inherits ResidueBase.
Friends | |
| class | ChainView |
Adding and removing atoms | |
| AtomView | AddAtom (const AtomView &atom_view, ViewAddFlags flags=0) |
| AtomView | AddAtom (const AtomHandle &atom_handle, ViewAddFlags flags=0) |
| AtomView | FindAtom (const String &atom_name) const |
| AtomView | ViewForHandle (const AtomHandle &handle) const |
| AtomView | FindAtom (const AtomHandle &handle) const |
| bool | IsAtomIncluded (const AtomHandle &handle) const |
| void | RemoveAtom (AtomView view) |
| void | RemoveAtoms () |
| void | Apply (EntityVisitor &visitor) |
| void | Apply (EntityViewVisitor &visitor) |
| int | GetAtomCount () const |
| const AtomViewList & | GetAtomList () const |
| ResidueHandle | GetHandle () const |
| EntityView | GetEntity () const |
| int | GetIndex () const |
| ChainView | GetChain () const |
| double | GetMass () const |
| geom::Vec3 | GetCenterOfMass () const |
| geom::Vec3 | GetCenterOfAtoms () const |
| geom::AlignedCuboid | GetBounds () const |
| EntityView | Select (const Query &q, QueryFlags flags=0) const |
| EntityView | Select (const String &query_string, QueryFlags flags=0) const |
| unsigned long | GetHashCode () const |
| bool | operator== (const ResidueView &rhs) const |
| bool | operator!= (const ResidueView &rhs) const |
| bool | HasAtoms () const |
| void | SetIndex (int index) |
Additional Inherited Members | |
Protected Member Functions inherited from ResidueBase | |
| GenericPropContainerImpl * | GpImpl () |
| const GenericPropContainerImpl * | GpImpl () const |
| void | CheckValidity () const |
Protected Member Functions inherited from ConstGenericPropContainer< H > | |
| template<typename T > | |
| T | gp_get (const String &key) const |
| template<typename T > | |
| T | gp_get (const String &key, const T &def) const |
| GenericPropContainerImpl * | GetImpl () |
| const GenericPropContainerImpl * | GetImpl () const |
residue view
Atoms are added with ResidueView::AddAtom() and removed with ResidueView::RemoveAtom(). Like other view operations, these operations only affect the view and do not alter the structure and topology of the underlying residue.
Definition at line 39 of file residue_view.hh.
| ResidueView | ( | ) |
Create invalid ResidueView.
| ResidueView | ( | const ChainView & | chain, |
| const ResidueHandle & | residue | ||
| ) |
Create new residue view.
| chain | is the parent chain view to insert into |
| residue | is residue handle this view points to. |
| ResidueView | ( | const ResidueViewDataPtr & | data, |
| const impl::ResidueImplPtr & | impl | ||
| ) |
construct new view from view data and impl.
This has the same effect as using the default copy constructor of the view.
| AtomView AddAtom | ( | const AtomHandle & | atom_handle, |
| ViewAddFlags | flags = 0 |
||
| ) |
Add atom to view.
If ViewAddFlag::CHECK_DUPLICATES is set, the method will ensure that the handle is not already included in the view.
| atom_handle | the atom handle to add |
| flags | can be a ORed together combination of ViewAddFlag |
| AtomView AddAtom | ( | const AtomView & | atom_view, |
| ViewAddFlags | flags = 0 |
||
| ) |
Add atom to view.
If ViewAddFlag::CHECK_DUPLICATES is set, the method will ensure that the view is not already included in this view. This method is an alias for residue_view.AddAtom(atom_view.GetHandle())
| atom_view | is the atom view to add |
| flags | can be a ORed together combination of ViewAddFlag |
| void Apply | ( | EntityViewVisitor & | visitor | ) |
| void Apply | ( | EntityVisitor & | visitor | ) |
Apply entity visitor to whole chain.
| AtomView FindAtom | ( | const AtomHandle & | handle | ) | const |
| int GetAtomCount | ( | ) | const |
return number of atoms in this residue view.
| const AtomViewList & GetAtomList | ( | ) | const |
get list of atoms in this view
| geom::AlignedCuboid GetBounds | ( | ) | const |
Get residue's axis-aligned bounding box.
| geom::Vec3 GetCenterOfAtoms | ( | ) | const |
Get residue's center of atoms (not mass weighted)
Returns the center of all the atoms in this residue. This is similar to GetCenterOfMass(), but the atoms are not mass weighted
| geom::Vec3 GetCenterOfMass | ( | ) | const |
Get residue's center of mass (mass weighted)
| ChainView GetChain | ( | ) | const |
get parent chain view.
| EntityView GetEntity | ( | ) | const |
get entity
| ResidueHandle GetHandle | ( | ) | const |
get handle this view points to
| unsigned long GetHashCode | ( | ) | const |
get unique id
The unique id is the same for all ResidueViews pointing to the same residue view data.
| int GetIndex | ( | ) | const |
get index of residue view in chain
| double GetMass | ( | ) | const |
Get residue's mass.
| bool HasAtoms | ( | ) | const |
| bool IsAtomIncluded | ( | const AtomHandle & | handle | ) | const |
Check whether the view includes the the given atom.
| bool IsValid | ( | ) | const |
check validity of handle
|
inline |
check validity of view
check, whether the residue view points to a valid residue.
Definition at line 65 of file residue_view.hh.
| bool operator!= | ( | const ResidueView & | rhs | ) | const |
| bool operator== | ( | const ResidueView & | rhs | ) | const |
| void RemoveAtom | ( | AtomView | view | ) |
remove given atom from view
all bonds involving this atom will be removed from the view as well.
| void RemoveAtoms | ( | ) |
remove all atoms
all bonds involving one of the atoms will be removed from the view as well.
| EntityView Select | ( | const Query & | q, |
| QueryFlags | flags = 0 |
||
| ) | const |
return view based on a query object
| EntityView Select | ( | const String & | query_string, |
| QueryFlags | flags = 0 |
||
| ) | const |
return view based on query String.
|
protected |
set the index of residiue view in chain should be called from chainview whenever indexes change
|
inline |
Get internal view data.
Definition at line 84 of file residue_view.hh.
|
inline |
Get internal view data.
Definition at line 80 of file residue_view.hh.
| AtomView ViewForHandle | ( | const AtomHandle & | handle | ) | const |
Find residue by residue handle.
|
friend |
Definition at line 41 of file residue_view.hh.