Loading...
Searching...
No Matches
BALL::FragmentDistanceCollector Class Reference
Molecular Modeling » Molecular Structure » Geometric property processors.

`#include <BALL/STRUCTURE/geometricProperties.h>`

Inheritance diagram for BALL::FragmentDistanceCollector:

## Public Member Functions

Constructors and Destructors
| FragmentDistanceCollector ()
| FragmentDistanceCollector (const Composite &composite)
| FragmentDistanceCollector (const Composite &composite, float distance)
virtual | ~FragmentDistanceCollector ()
Processor related methods
virtual bool | start ()
virtual bool | finish ()
virtual Processor::Result | operator() (const Composite &composite)
Public Member Functions inherited from BALL::ConstUnaryProcessor< Composite >
virtual | ~ConstUnaryProcessor ()

## Accessors

std::vector< const Fragment * > | fragments
std::vector< const Fragment * > | all_fragments_
const Composite * | reference_composite_
float | squared_distance_
Size | getNumberOfFragments ()
void | setComposite (const Composite &composite)
const Composite * | getComposite () const
float | getDistance () const
void | setDistance (float distance)

## Additional Inherited Members

Public Types inherited from BALL::UnaryFunctor< ArgumentType, ResultType >
typedef ResultType | result_type
typedef ArgumentType | argument_type
typedef ArgumentType & | argument_reference
typedef const ArgumentType & | const_argument_reference
typedef ArgumentType * | argument_pointer
typedef const ArgumentType * | const_argument_pointer

## Detailed Description

Collects all MolecularFragments that are close enough to another molecular fragment. This processor examines the distances between every atom of a given fragment (further referred to as the reference fragment) and all other atoms in a molecular object he is applied to. If any atom of a fragment is closer to any atom of the reference fragment, the whole fragment is collected in an array.

  The reference fragment itself is also contained in this array, if it is part of the molecular object the collector is applied to.

  The array only contains pointers to the fragments, the fragments are neither changed, nor removed from the molecular object.

  The reference fragment may either be given by a specialized constructor (also together with the distance) or using setFragment .

  The fragment array is emptied prior to each collection run.

Definition at line 198 of file geometricProperties.h.

## Constructor & Destructor Documentation

## FragmentDistanceCollector() [1/3]

BALL::FragmentDistanceCollector::FragmentDistanceCollector | ( |  | ) |

Default constructor

## FragmentDistanceCollector() [2/3]

BALL::FragmentDistanceCollector::FragmentDistanceCollector | ( | const Composite & | composite | ) |

Constructor. Creates a new collector and sets the reference composite

Parameters

  composite | the reference composite

## FragmentDistanceCollector() [3/3]

BALL::FragmentDistanceCollector::FragmentDistanceCollector | ( | const Composite & | composite,
|  | float | distance )

Constructor. Creates a new collector and sets the reference composite and the distance.

Parameters

  composite | the reference composite
  distance | the maximum distance between any two atoms

## ~FragmentDistanceCollector()

virtual BALL::FragmentDistanceCollector::~FragmentDistanceCollector | ( |  | ) |

inline virtual

Definition at line 227 of file geometricProperties.h.

## Member Function Documentation

## finish()

virtual bool BALL::FragmentDistanceCollector::finish | ( |  | ) |

virtual

Reimplemented from BALL::ConstUnaryProcessor< Composite >.

## getComposite()

const Composite * BALL::FragmentDistanceCollector::getComposite | ( |  | ) | const

Gets the reference composite

Returns
  a const pointer to the reference composite

## getDistance()

float BALL::FragmentDistanceCollector::getDistance | ( |  | ) | const

Gets the maximum distance

Returns
  the maximum distance

## getNumberOfFragments()

Size BALL::FragmentDistanceCollector::getNumberOfFragments | ( |  | ) |

Returns the number of molecular fragments found

Returns
  the number of fragments in the array

## operator()()

virtual Processor::Result BALL::FragmentDistanceCollector::operator() | ( | const Composite & | composite | ) |

virtual

Reimplemented from BALL::ConstUnaryProcessor< Composite >.

## setComposite()

void BALL::FragmentDistanceCollector::setComposite | ( | const Composite & | composite | ) |

Sets the reference composite

Parameters

  composite | the new reference composite

## setDistance()

void BALL::FragmentDistanceCollector::setDistance | ( | float | distance | ) |

Sets the maximum distance

Parameters

  distance | the new maximum distance

## start()

virtual bool BALL::FragmentDistanceCollector::start | ( |  | ) |

virtual

Reimplemented from BALL::ConstUnaryProcessor< Composite >.

## Member Data Documentation

## all_fragments_

std::vector<const Fragment*> BALL::FragmentDistanceCollector::all_fragments_

protected

Definition at line 294 of file geometricProperties.h.

## fragments

std::vector<const Fragment*> BALL::FragmentDistanceCollector::fragments

The array containing all molecular fragments collected

Definition at line 289 of file geometricProperties.h.

## reference_composite_

const Composite* BALL::FragmentDistanceCollector::reference_composite_

protected

Definition at line 295 of file geometricProperties.h.

## squared_distance_

float BALL::FragmentDistanceCollector::squared_distance_

protected

Definition at line 296 of file geometricProperties.h.