RSB
0.7.0
|
This filter matches events that originate from a particular participant. More...
#include <OriginFilter.h>
Public Member Functions | |
OriginFilter (const rsc::misc::UUID &origin, bool invert=false) | |
Creates a new origin filter that matches event originating from origin. | |
rsc::misc::UUID | getOrigin () const |
bool | isInverted () const |
bool | match (EventPtr e) |
Matches the given event against the constraints specified by this filter. | |
void | notifyObserver (FilterObserverPtr fo, FilterAction::Types at) |
Double-dispatch method to notfify a FilterObserver about changes for this filter with a more specific type that the general Filter interface. | |
Public Member Functions inherited from rsb::filter::Filter | |
Filter () | |
virtual | ~Filter () |
Private Attributes | |
rsc::misc::UUID | origin |
bool | invert |
This filter matches events that originate from a particular participant.
Definition at line 43 of file OriginFilter.h.
rsb::filter::OriginFilter::OriginFilter | ( | const rsc::misc::UUID & | origin, |
bool | invert = false |
||
) |
Creates a new origin filter that matches event originating from origin.
origin | Id of the participant from which matching events have to originate. |
invert | If true, events match if they do not originate from origin. |
Definition at line 37 of file OriginFilter.cpp.
UUID rsb::filter::OriginFilter::getOrigin | ( | ) | const |
Definition at line 42 of file OriginFilter.cpp.
References origin.
bool rsb::filter::OriginFilter::isInverted | ( | ) | const |
Definition at line 46 of file OriginFilter.cpp.
References invert.
|
virtual |
Matches the given event against the constraints specified by this filter.
e | the event to match. Must not be changed! |
true
if the event matches the restrictions specified by this filter and hence can be delivered to the client, false
to remove the event from the stream. Implements rsb::filter::Filter.
Definition at line 50 of file OriginFilter.cpp.
|
virtual |
Double-dispatch method to notfify a FilterObserver about changes for this filter with a more specific type that the general Filter interface.
The default implementation does not generate a specific notification on FilterObserver. Override this method if there is a specific reception method in FilterObserver.
fo | the observer to notify |
at | action that is performed with this filter. Just pass this to the observer |
Reimplemented from rsb::filter::Filter.
Definition at line 55 of file OriginFilter.cpp.
|
private |
Definition at line 66 of file OriginFilter.h.
Referenced by isInverted(), and match().
|
private |
Definition at line 65 of file OriginFilter.h.
Referenced by getOrigin(), and match().