dateTimeEqual Function Description

Description

The dateTimeEqual function compares two atomic values of type dateTime and returns true if and only if the 2 arguments to the function are equal according to the equality rules defined by the dateTime type.

dateTimeEqual belongs to the ALFA function reference's equality predicates category. It maps to the XACML function identifier urn:oasis:names:tc:xacml:1.0:function:dateTime-equal, takes 2 arguments and returns a value of type boolean.

Property Value
Category equality predicates
# Arguments 2
Arguments
  • 2 atomic values of type dateTime
Return Value boolean
Expressed As in-fix
Representation a == b
Allowed In Target true
ALFA Shorthand ==
Commutative true

Example

/**
 * This rule will return Permit if the requested dateTime attribute is equal to (or
 * contains) the value 2001-04-01T12:00:00-05:00.
 */
rule dateTimeEqualExample{
    target clause requestedDateTimes=="2002-10-10T12:00:00-05:00":dateTime
    permit
}

In this example, the rule will return Permit if the requested dateTime attribute is equal to the value 2001-04-01T12:00:00-05:00.