# PhasicFlow: eventObserver Class Reference

eventObserver Class Referenceabstract
Inheritance diagram for eventObserver:
[legend]
Collaboration diagram for eventObserver:
[legend]

## Public Member Functions

| eventObserver ()
| eventObserver (const eventSubscriber &subscriber, bool subscribe=true)
virtual | ~eventObserver ()
bool | subscribed () const
bool | subscribe (const eventSubscriber &subscriber)
void | invalidateSubscriber ()
virtual bool | update (const eventMessage &msg)=0

## Protected Attributes

const eventSubscriber * | subscriber_ = nullptr
bool | subscribed_ = false

## Detailed Description

Definition at line 33 of file eventObserver.hpp.

## Constructor & Destructor Documentation

## eventObserver() [1/2]

eventObserver | ( |  | ) |

Definition at line 24 of file eventObserver.cpp.

## eventObserver() [2/2]

eventObserver | ( | const eventSubscriber & | subscriber,
|  | bool | subscribe = `true`
| ) |  |

Definition at line 30 of file eventObserver.cpp.

## ~eventObserver()

~eventObserver | ( |  | ) |

virtual

Definition at line 44 of file eventObserver.cpp.

## Member Function Documentation

## subscribed()

bool subscribed | ( |  | ) | const

inline

Definition at line 50 of file eventObserver.hpp.

References eventObserver::subscribed_.

## subscribe()

bool subscribe | ( | const eventSubscriber & | subscriber | ) |

Definition at line 50 of file eventObserver.cpp.

References eventSubscriber::subscribe().

Here is the call graph for this function:

## invalidateSubscriber()

void invalidateSubscriber | ( |  | ) |

inline

Definition at line 54 of file eventObserver.hpp.

References eventObserver::subscribed_.

## update()

virtual bool update | ( | const eventMessage & | msg | ) |

pure virtual

Implemented in sphereInteraction< contactForceModel, geometryMotionModel, contactListType >, sphereParticles, dynamicPointStructure, pointField< VectorField, T, MemorySpace >, pointField< T >, and triSurfaceField< VectorField, T, MemorySpace >.

Referenced by eventSubscriber::notify().

Here is the caller graph for this function:

## Member Data Documentation

## subscriber_

const eventSubscriber* subscriber_ = nullptr

protected

Definition at line 37 of file eventObserver.hpp.

## subscribed_

bool subscribed_ = false

protected

Definition at line 40 of file eventObserver.hpp.

Referenced by eventObserver::invalidateSubscriber(), and eventObserver::subscribed().

The documentation for this class was generated from the following files:

- src/phasicFlow/eventSubscriber/eventObserver.hpp
- src/phasicFlow/eventSubscriber/eventObserver.cpp