Class Observer

Inheritance Relationships

Base Type

Class Documentation

class Observer : public Module

General particle observer.

Public Functions

Observer()

Default observer constructor

void add(ObserverFeature *feature)

Add a feature to the observer

Parameters:

feature – observer feature to be added to the Observer object

void onDetection(Module *action, bool clone = false)

Perform some specific actions upon detection of candidate

Parameters:
  • action – module that performs a given action when candidate is detected

  • clone – if true, clone candidate

virtual void process(Candidate *candidate) const
virtual std::string getDescription() const
void setFlag(std::string key, std::string value)
void setDeactivateOnDetection(bool deactivate)

Determine whether candidate should be deactivated on detection

Parameters:

deactivate – if true, deactivate detected particles; if false, continue tracking them

void setDescription(const std::string &description)
inline void process(ref_ptr<Candidate> candidate) const
inline size_t addReference() const
inline size_t removeReference() const
inline int removeReferenceNoDelete() const
inline size_t getReferenceCount() const

Protected Attributes

mutable size_t _referenceCount