Operator | Description |
[value1:value2] | Specifies a range of values that can match. The values themselves are included in the range to match against. For example: on stockPrice(*, [0 : 10]) doSomething(); This example will invoke the doSomething() action if a stockPrice event is received where the price is between 0 and 10 inclusive. You can apply this range operator to decimal, float, integer and string types. |
[value1:value2) | Specifies a range of values that can match. The first value itself is included in the range to match against while the second value is excluded from the range to match against. For example: on stockPrice(*, [0 : 10)) doSomething(); This example will invoke the doSomething() action if a stockPrice event is received where the price is between 0 and 9 inclusive (assuming the field was of integer type). You can apply this range operator to decimal, float, integer and string types. |
(value1:value2] | Specifies a range of values that can match. The first value is excluded from the range to match against while the second value is included. For example: on stockPrice(*, (0 : 10]) doSomething(); This example invokes the doSomething() action if a stockPrice event is received where the price is between 1 and 10 inclusive (assuming the field was an integer). This operator can apply to decimal, float, integer and string types. |
(value1:value2) | Specifies a range of values that can match. The values themselves are excluded from the range to match against. For example: on stockPrice(*, (0 : 10)) doSomething(); This example will invoke the doSomething() action if a stockPrice event is received where the price is between 1 and 9 inclusive (assuming the field was of integer type).You can apply this range operator to decimal, float, integer and string types. |
> value | All values greater than the value supplied will satisfy the condition for a match.You can apply this operator to decimal, float, integer, and string types. When used with a string, the operator assumes lexical ordering. |
< value | All values less than the value supplied will satisfy the condition for a match. You can apply this operator to decimal, float, integer, and string types. When used with a string, the operator assumes lexical ordering. |
>= value | All values greater than or equal to the value supplied will satisfy the condition for a match. You can apply this operator to decimal, float, integer, and string types. When used with a string, the operator assumes lexical ordering. |
<= value | All values less than or equal to the value supplied will satisfy the condition for a match. You can apply this operator to decimal, float, integer, and string types. When used with a string, the operator assumes lexical ordering. |
= value | All values equal to the value supplied will satisfy the condition for a match. You can apply this operator to decimal, float, integer, and string types. When used with a string, the operator assumes lexical ordering. |
value | With one exception, only a value equivalent to the value supplied will satisfy the condition for a match. The exception is a location type field. A location value consists of a structure with four floats representing the coordinates of the corners of the rectangular space being represented. A listener that is watching for a particular value for a location field matches when it finds a location field that intersects with the location value specified in the listener’s event expression. In the following example, the listener matches each A event whose loc field specifies a location that intersects with the square defined by (0.0, 0.0, 1.0, 1.0). location l := location(0.0, 0.0, 1.0, 1.0); on all A(loc = l) ... |
* | Any value for this field satisfies the condition for a match. |