Warning:
This wiki has been archived and is now read-only.
Constraints in ODRL
Since we are always short on time in our calls, I'm trying to outline my thoughts on constraints in ODRL now here.
Status Quo
Currently, the ODRL Information Model ED defines constraints in ODRL as follows:
Definition of ODRL Constraints (as of 11/08/2016) The Constraint
entity indicates limits and restrictions to thePermission
, theProhibition
and theDuty
entity.Constraint
s express mathematical terms with two operands and one operator. For example, the "number of usages" (name
) must be "smaller than" (operator
) the "number 10" (rightOperand
).If multiple
Constraint
entities are linked to the samePermission
,Prohibition
, orDuty
entity, then all of theConstraint
entities MUST be satisfied. That is, all theConstraint
entities are (boolean) ANDed. In the case where the sameConstraint
is repeated, then these MUST be represented as a singleConstraint
entity using an appropriateoperator
value (for example,isAnyOf
).The
Constraint
entity contains the following attributes:-
name
: a name that identifies the left operand of the operation (REQUIRED) -
operator
: an operator function (REQUIRED) -
rightOperand
: the right operand of the operation (REQUIRED) -
dataType
: the datatype of the rightOperand (OPTIONAL) -
unit
: the units of the rightOperand (OPTIONAL) -
status
: the current value of the left operand (OPTIONAL)
The
name
identifies the left operand of the mathematical operation for theConstraint
such as "Number of Usages" and "Expiration Date" etc. Theoperator
identifies the comparative operation such as "greater than" or "equal to". TherightOperand
identifies the value that is being compared. ThedataType
indicates the type of therightOperand
, such as "decimal" or "datetime" and the unit indicates the unit value of therightOperand
, such as "EU dollars".When processing policy expressions, these
Constraint
names <ref>i.e., the left operand?</ref> MAY be directly linked to a procedure that can determine the outcome of the operations, such as the number of already performed usages and the current date. Thename
andoperator
are defined in the ODRL Vocabulary or community profiles.The
status
provides the current value of theConstraint
variable (i.e. current value ofname
). This is useful in cases where the current status ofConstraint
s needs to be captured and expressed in the ODRL Information Model.-
tbd
<references />