...
Sakai has a built-in mechanism for responding to events, called the NotificationService
. Clients of the service ask it to create objects of type Notification
. The Notification
extends Sakai Entity
and specifies three additional key pieces of information: Excerpt
hidden | true |
---|
- one or more strings containing event types to respond to. These are called functions.
- a string called a resource filter which indicates which resource may be affected by the event.
- an object of type
NotificationAction
which has thenotify()
method for taking action in response to the event.
...
The conditions module contains an implementation of NotificationAction
called ResourceReleaseRule
, which also implements Predicate
from Apache commons-collections. The purpose of Predicate
is to add a boolean evaluate(Object arg)
method which answers the question "Has the condition been met?" The notify()
method checks the condition and then takes the necessary action to update the state of the ContentHostingService
.
...