Package jason.stdlib

Class eval

All Implemented Interfaces:
InternalAction, Serializable

@Manual(literal=".eval(term,query)", hint="evaluates the logical expression (which computes to true or false), the result is unified with term", argsHint={"the variable that unifies with the result of evaluation","the formula that is evaluated"}, argsType={"variable, atoms true or false","logical formula"}, examples={".eval(X, true | false): X unifies with true",".eval(X, 3<5 & not 4+2<3): X unifies with true"}, seeAlso="") public class eval extends DefaultInternalAction

Internal action: .eval(Var,Logical Expression).

Description: evaluates the logical expression (which computes to true or false), the result is unified with Var.

Parameters:

  • + term (variable, atoms true or false): the variable that unifies with the result of evaluation.
  • + query (logical formula): the formula that is evaluated.

Examples:

  • .eval(X, true | false): X unifies with true.
  • .eval(X, 3invalid input: '<'5 invalid input: '&' not 4+2invalid input: '<'3): X unifies with true.
See Also: