abstract class obix::ObixModWatch
sys::Obj obix::ObixModWatch
ObixMod hooks for implementing server side watches. ObixMod manages the networking/protocol side of things, but subclasses are responsible for managing the actual URI subscription list and polling.
- add
-
abstract ObixObj[] add(Uri[] uris)
Add the given uris to watch and return current state. If there is an error for an individual uri, return an error object. Resulting objects must have hrefs which exactly match input uri.
- delete
-
abstract Void delete()
Handle delete/cleanup of watch.
- id
-
abstract Str id()
Get unique idenifier for the watch. This string must be safe to use within a URI path (should not contain special chars or slashes)
- lease
-
abstract Duration lease
Get/set lease time
- pollChanges
-
abstract ObixObj[] pollChanges()
Poll URIs which have changed since last poll. Resulting objects must have hrefs which exactly match input uri.
- pollRefresh
-
abstract ObixObj[] pollRefresh()
Poll all URIs in this watch. Resulting objects must have hrefs which exactly match input uri.
- remove
-
abstract Void remove(Uri[] uris)
Remove the given uris from the watch. Silently ignore bad uris.
- toObixObj
-
virtual ObixObj toObixObj()
Map server side representation to its on-the-wire Obix representation.
- toStr
-
virtual override Str toStr()
Debug string