Adaptation Rules Example


Let's see an example of how these rules can be used

C: select P.access
   where P.access = true
A: update F.pres := "show"
   where part-of(F,P) and F.relevant = true


Another example

C: select P.access
   where P.access = true and P.ready_to_read = true
A: update F.pres := "show"
   where part-of(F,P) and F.relevant = true


A slightly more complex example

C: select C1.knowledge
   where C1.knowledge >= "known"
A: update C2.read_to_read := true
   where prerequisite(C1, C2) and
     not exists( select C3
                 where prequisite(C3,C2) and C3.knowledge < "known"


One final example

C: select C1.knowledge
   where C1.knowledge = "well known"
A: update C2.ready_to_read := false
   where inhibit(C1,C2)