Class Rule
java.lang.Object
com.appiancorp.suiteapi.process.events.Rule
- All Implemented Interfaces:
Serializable
Represents a single condition in the set of conditions on an event trigger.
Not to be confused with a content rule, which is a stored expression usable
within other expressions throughout the application.
An event trigger condition (rule) must evaluate to a boolean.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the expression, which should evaluate to a boolean.Gets the left operand in a simple rule.Gets the operator in a simple rule.Gets the right operand in a simple rule.getType()Gets the type of the rule (eitherSIMPLE_RULEorCOMPLEX_RULE).voidsetExpression(String expression_) Sets the expression, which should evaluate to a boolean.voidsetLeftOperand(String leftOperand_) Sets the left operand in a simple rule.voidsetOperator(String operator_) Sets the operator in a simple rule.voidsetRightOperand(String rightOperand_) Sets the right operand in a simple rule.voidSets the type of the rule (eitherSIMPLE_RULEorCOMPLEX_RULE).
-
Field Details
-
SIMPLE_RULE
Type code for a simple rule (consists of left operand, operator, and right operand). This displays in the modeler as two text fields and a dropdown in the middle for the operand. This is called a "Condition" in the modeler (e.g., the button to add this says "Add Condition"). -
COMPLEX_RULE
Type code for a complex rule (can be any expression). This displays in the modeler as a single text field.
-
-
Constructor Details
-
Rule
public Rule()
-
-
Method Details
-
getExpression
Gets the expression, which should evaluate to a boolean. Only applicable ifgetType()returnsCOMPLEX_RULE. Otherwise, this will returnnull.- Returns:
- the expression
- See Also:
-
setExpression
Sets the expression, which should evaluate to a boolean. Only applicable ifgetType()returnsCOMPLEX_RULE.- Parameters:
expression_- the expression- See Also:
-
getLeftOperand
Gets the left operand in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE. Otherwise, this will returnnull.- Returns:
- the left operand
- See Also:
-
setLeftOperand
Sets the left operand in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE.- Parameters:
leftOperand_- the left operand- See Also:
-
getOperator
Gets the operator in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE. Otherwise, this will returnnull.- Returns:
- the left operand
- See Also:
-
setOperator
Sets the operator in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE.- Parameters:
operator_- the operator- See Also:
-
getRightOperand
Gets the right operand in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE. Otherwise, this will returnnull.- Returns:
- the right operand
- See Also:
-
setRightOperand
Sets the right operand in a simple rule. Only applicable ifgetType()returnsSIMPLE_RULE.- Parameters:
rightOperand_- the right operand- See Also:
-
getType
Gets the type of the rule (eitherSIMPLE_RULEorCOMPLEX_RULE).- Returns:
- the type
- See Also:
-
setType
Sets the type of the rule (eitherSIMPLE_RULEorCOMPLEX_RULE).- Parameters:
type_- the type- See Also:
-