OriginFilter¶
-
public class
OriginFilter
implements Filter¶ Events matched by this filter have to originate from a particular participant.
- Author
swrede, jmoringe
Constructors¶
OriginFilter¶
-
public
OriginFilter
(ParticipantId origin, boolean invert)¶ Constructor.
- Parameters
origin – the desired origin of a received event, not
null
invert – if
true
, suppress events from the provided origin and allow all other events instead of only allowing events from that origin.
- Throws
IllegalArgumentException – origin is
null
OriginFilter¶
-
public
OriginFilter
(ParticipantId origin)¶ Constructor.
- Parameters
origin – only events from this origin are allowed, not
null
- Throws
IllegalArgumentException – origin is
null
Methods¶
getOrigin¶
-
public ParticipantId
getOrigin
()¶ Returns the origin participant id this filter operates for.
- Returns
the id, not
null
isInverted¶
-
public boolean
isInverted
()¶ Indicates whether the filter accepts events only from the id returned by
getOrigin()
or it only accepts events that do not originate from that origin.- Returns
if
true
, only events NOT originating fromgetOrigin()
are allowed. Iffalse
, only events fromgetOrigin()
are allowed.