C++ Native Functions: com.teracloud.streams.evalpredicate
- <tuple T1> public void compare_tuple_attributes(T1 myTuple1, T1 myTuple2, mutable list<rstring> matchingAttributes, mutable list<rstring> differingAttributes, mutable int32 error, boolean trace)
-
Compares the attribute values of two tuples that are made of the same schema and returns a list containing the attribute names that have matching values and another list containing the attribute names that have differing values.
- Parameters
-
- myTuple1
-
First of the two user given tuples to be compared. Type: Tuple
- myTuple2
-
Second of the two user given tuples to be compared. Type: Tuple
- matchingAttributes
-
A mutable list variable that will contain the attribute names that have matching values. Type: list<rstring>
- differingAttributes
-
A mutable list variable that will contain the attribute names that have differing values. Type: list<rstring>
- error
-
A mutable variable that will contain a non-zero error code if an error occurs. Type: int32
- trace
-
A boolean value to enable tracing inside this function. Type: boolean
- <tuple T> public boolean eval_predicate(rstring expr, T myTuple, mutable int32 error, boolean trace)
-
Evaluates a user defined rule (i.e. expression) represented as an rstring using the given tuple.
- Parameters
-
- expr
-
User defined rule (expression) to be evaluated i.e. processed. Type: rstring
- myTuple
-
A user defined tuple whose attributes the rule (expression) should refer to. Type: Tuple
- error
-
A mutable variable that will contain a non-zero error code if a rule processing error occurs. Type: int32
- trace
-
A boolean value to enable tracing inside this function. Type: boolean
- Returns
-
true when the rule evaluation i.e. processing is successful. Otherwise, false. Type: boolean
- <tuple T1, any T2> public void get_tuple_attribute_value(rstring attributeName, T1 myTuple, mutable T2 value, mutable int32 error, boolean trace)
-
Fetches the value of a user given attribute name if it is present in the user given tuple.
- Parameters
-
- attributeName
-
A user given fully qualified attribute name. Type: rstring
- myTuple
-
A user defined tuple in which the user given attribute is present. Type: Tuple
- value
-
A mutable variable in which the value of a user given attribute will be returned. Type: An appropriate type
- error
-
A mutable variable that will contain a non-zero error code if an error occurs. Type: int32
- trace
-
A boolean value to enable tracing inside this function. Type: boolean
- <tuple T1> public void get_tuple_schema_and_attribute_info(T1 myTuple, mutable rstring schema, mutable map<rstring, rstring> attributeInfo, mutable int32 error, boolean trace)
-
Fetches the schema literal string of a given tuple along with the information about all of its attributes.
- Parameters
-
- myTuple
-
A user defined tuple for which schema and attribute information will be obtained. Type: Tuple
- schema
-
A mutable variable in which the complete schema literal string of a given tuple will be returned. Type: rstring
- attributeInfo
-
A mutable map variable in which information about the tuple attributes will be returned. Map key will carry the fully qualified name of a given tuple attribute and map value will carry the SPL type name of that attribute. Type: map<rstring, rstring>
- error
-
A mutable variable that will contain a non-zero error code if an error occurs. Type: int32
- trace
-
A boolean value to enable tracing inside this function. Type: boolean