Warning:
This wiki has been archived and is now read-only.
YoungParentDiscount 1
From RIF
(Redirected from YoungParentDiscount1)
Test Type | PositiveEntailmentTest | ||||||
---|---|---|---|---|---|---|---|
Contributor | Axel Polleres | ||||||
Status | Approved | ||||||
Record | 9 June 2009 telecon | ||||||
Dialect | BLD | ||||||
Purpose | This test case illustrates the use of guard predicates with built-ins, as well as RDF+BLD combinations. | ||||||
Description | The first rule says that a child is eligible for a "young-parents" discount if the difference between the child's age and one of the parent's age is less than 25 years. The second rule says that if a parent's age is not numeric, the parent will be marked as needing to be checked for eligibility. Note that external built-ins can be nested arbitrarily. Note also that built-ins in RIF are defined for arguments of specific datatypes. When an argument is not of the appropriate datatype, it is an error. Since the model-theoretic semantics for RIF does not include the notion of an error, the values of built-in predicates and functions are unspecified in such cases. In order to enable writing of rule sets with controlled behavior, RIF defines guard predicates for each datatype. | ||||||
SeeAlso | YoungParentDiscount_2 | ||||||
SpecRef | http://www.w3.org/2005/rules/wiki/DTB#Guard_Predicates_for_Datatypes | ||||||
ImportedDocument |
| ||||||
Premises |
|
||||||
Conclusion |
|