Applicable only to Quantifier.looping() and Quantifier.times() patterns, this option allows more flexibility to the matching events.
Applicable only to Quantifier.looping() and Quantifier.times() patterns, this option allows more flexibility to the matching events.
If
allowCombinations()
is not applied for a pattern
A.oneOrMore().followedBy(B)
and a sequence of events
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A.oneOrMore().followedBy(B) }}}
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
allowCombinations() }}} pattern
A.oneOrMore().followedBy(B)
and a sequence of events
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A.oneOrMore().followedBy(B) }}}
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. If this method is applied, we will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 A2 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
A1 B }}} will have
A1 B
,
A2 B
and
A1 A2 B
.
A1 A2 B }}}
A2 B }}}
A1 B }}}
The same pattern with the updated quantifier.
MalformedPatternException
if the quantifier is not applicable to this pattern.
Works in conjunction with Pattern#oneOrMore() or Pattern#times(int).
Works in conjunction with Pattern#oneOrMore() or Pattern#times(int). Specifies that any not matching element breaks the loop.
E.g. a pattern like:
Pattern.begin("start").where(_.getName().equals("c")) .followedBy("middle").where(_.getName().equals("a")).oneOrMore().consecutive() .followedBy("end1").where(_.getName().equals("b"));
For a sequence: C D A1 A2 A3 D A4 B
will generate matches: {C A1 B}, {C A1 A2 B}, {C A1 A2 A3 B}
By default a relaxed continuity is applied.
pattern with continuity changed to strict
Appends a new group pattern to the existing one.
Appends a new group pattern to the existing one. The new pattern enforces non-strict temporal contiguity. This means that a matching event of this pattern and the preceding matching event might be interleaved with other events which are ignored.
the pattern to append
A new pattern which is appended to this one
Appends a new pattern to the existing one.
Appends a new pattern to the existing one. The new pattern enforces non-strict temporal contiguity. This means that a matching event of this pattern and the preceding matching event might be interleaved with other events which are ignored.
Name of the new pattern
A new pattern which is appended to this one
Appends a new group pattern to the existing one.
Appends a new group pattern to the existing one. The new pattern enforces non-strict temporal contiguity. This means that a matching event of this pattern and the preceding matching event might be interleaved with other events which are ignored.
the pattern to append
A new pattern which is appended to this one
Appends a new pattern to the existing one.
Appends a new pattern to the existing one. The new pattern enforces non-strict temporal contiguity. This means that a matching event of this pattern and the preceding matching event might be interleaved with other events which are ignored.
Name of the new pattern
A new pattern which is appended to this one
Get after match skip strategy.
Get after match skip strategy.
current after match skip strategy
Name of the pattern operator
The previous pattern
currently applied quantifier to this pattern
Window length in which the pattern match has to occur
Specifies that this pattern is greedy.
Specifies that this pattern is greedy. This means as many events as possible will be matched to this pattern.
The same pattern with { @link Quantifier#greedy} set to true.
MalformedPatternException
if the quantifier is not applicable to this pattern.
Appends a new group pattern to the existing one.
Appends a new group pattern to the existing one. The new pattern enforces strict temporal contiguity. This means that the whole pattern sequence matches only if an event which matches this pattern directly follows the preceding matching event. Thus, there cannot be any events in between two matching events.
the pattern to append
A new pattern which is appended to this one
Appends a new pattern to the existing one.
Appends a new pattern to the existing one. The new pattern enforces strict temporal contiguity. This means that the whole pattern sequence matches only if an event which matches this pattern directly follows the preceding matching event. Thus, there cannot be any events in between two matching events.
Name of the new pattern
A new pattern which is appended to this one
Appends a new pattern to the existing one.
Appends a new pattern to the existing one. The new pattern enforces that there is no event matching this pattern between the preceding pattern and succeeding this one.
NOTE: There has to be other pattern after this one.
Name of the new pattern
A new pattern which is appended to this one
Appends a new pattern to the existing one.
Appends a new pattern to the existing one. The new pattern enforces that there is no event matching this pattern right after the preceding matched event.
Name of the new pattern
A new pattern which is appended to this one
Specifies that this pattern can occur
Specifies that this pattern can occur
one or more
times. This means at least one and at most infinite number of events can be matched to this pattern.
If this quantifier is enabled for a pattern
A.oneOrMore().followedBy(B)
and a sequence of events
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A.oneOrMore().followedBy(B) }}}
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
one or more }}} This means at least one and at most infinite number of events can be matched to this pattern.
If this quantifier is enabled for a pattern
A.oneOrMore().followedBy(B)
and a sequence of events
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A.oneOrMore().followedBy(B) }}}
A1 A2 B
appears, this will generate patterns:
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
A1 A2 B }}}
A1 B
and
A1 A2 B
. See also
allowCombinations()
.
allowCombinations() }}}
A1 A2 B }}}
A1 B }}}
The same pattern with a Quantifier.looping() quantifier applied.
MalformedPatternException
if the quantifier is not applicable to this pattern.
Specifies that this pattern is optional for a final match of the pattern sequence to happen.
Specifies that this pattern is optional for a final match of the pattern sequence to happen.
The same pattern as optional.
MalformedPatternException
if the quantifier is not applicable to this pattern.
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
OR
. In other case, this is going to be the only condition.
OR }}} condition.
The
OR
The pattern with the new condition is set.
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
OR
. In other case, this is going to be the only condition.
OR }}} condition.
The
OR
The pattern with the new condition is set.
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
OR
. In other case, this is going to be the only condition.
OR }}} condition.
The condition as an IterativeCondition.
The pattern with the new condition is set.
Applies a subtype constraint on the current pattern.
Applies a subtype constraint on the current pattern. This means that an event has to be of the given subtype in order to be matched.
Type of the subtype
Class of the subtype
The same pattern with the new subtype constraint
Specifies that the pattern can occur between from and to times.
Specifies that the pattern can occur between from and to times.
number of times matching event must appear at least
number of times matching event must appear at most
The same pattern with the number of times range applied
MalformedPatternException
if the quantifier is not applicable to this pattern.
Specifies exact number of times that this pattern should be matched.
Specifies exact number of times that this pattern should be matched.
number of times matching event must appear
The same pattern with number of times applied
MalformedPatternException
if the quantifier is not applicable to this pattern.
Specifies that this pattern can occur the specified times at least.
Specifies that this pattern can occur the specified times at least. This means at least the specified times and at most infinite number of events can be matched to this pattern.
The same pattern with a { @link Quantifier#looping(ConsumingStrategy)} quantifier applied.
MalformedPatternException
if the quantifier is not applicable to this pattern.
Applies a stop condition for a looping state.
Applies a stop condition for a looping state. It allows cleaning the underlying state.
a condition an event has to satisfy to stop collecting events into looping state
The same pattern with applied untilCondition
Applies a stop condition for a looping state.
Applies a stop condition for a looping state. It allows cleaning the underlying state.
a condition an event has to satisfy to stop collecting events into looping state
The same pattern with applied untilCondition
Applies a stop condition for a looping state.
Applies a stop condition for a looping state. It allows cleaning the underlying state.
a condition an event has to satisfy to stop collecting events into looping state
The same pattern with applied untilCondition
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
AND
. In other case, this is going to be the only condition.
AND }}} condition.
The condition to be set.
The pattern with the new condition is set.
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
AND
. In other case, this is going to be the only condition.
AND }}} condition.
The condition to be set.
The pattern with the new condition is set.
Adds a condition that has to be satisfied by an event in order to be considered a match.
Adds a condition that has to be satisfied by an event in order to be considered a match. If another condition has already been set, the new one is going to be combined with the previous with a logical
AND
. In other case, this is going to be the only condition.
AND }}} condition.
The condition as an IterativeCondition.
The pattern with the new condition is set.
Defines the maximum time interval in which a matching pattern has to be completed in order to be considered valid.
Defines the maximum time interval in which a matching pattern has to be completed in order to be considered valid. This interval corresponds to the maximum time gap between first and the last event.
Time of the matching window
The same pattern operator with the new window length
Base class for a pattern definition.
A pattern definition is used by org.apache.flink.cep.nfa.compiler.NFACompiler to create a org.apache.flink.cep.nfa.NFA.
Base type of the elements appearing in the pattern
Subtype of T to which the current pattern operator is constrained