Operation Class

An operation object represents an operation in an analytic calculation engine rule. The operation is generally some type of mathematical function performed between two operands. Specify the operands for the operation using the Operand1 and Operand2 operation class properties.

Use the following code to create an operation object:

&Comparison = create Operation(&Constants.Operation_Type);

Where Operation_Type has a value of one of the following:

Value

Description

Operation_Type_Plus

The operation is addition.

Operation_Type_Minus

The operation is subtraction.

Operation_Type_Mult

The operation is multiplication.

Operation_Type_Div

The operation is division.

Operation_Type_And

Use a logical AND with the operation.

Operation_Type_Or

Use a logical OR with the operation.

Operation_Type_Not

Use a logical NOT with the operation.

Operation_Type_Neg

Use a mathmatical negate with the operation.

Operation_Type_Exp

Use a mathmatical exponent with the operation.

The following code creates an operations that is a multiplication between two operands.

   &operation = create Operation(&Constants.Operation_Type_Mult);
   &Constant = create Constant(&Constants.Constant_Type_Literal, "PI");
   &operation.Operand1 = &Constant;
   &Constant = create Constant(&Constants.Constant_Type_Literal, "SLOPE");
   &operation.Operand2 = &Constant;
   &FunCall.AddArgument(&operation);