|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectti.chimera.Resource
ti.chimera.Plugin.RegistrySubscriberResource
A registry resource handles installing/uninstalling various registry
subscribers when the plugin becomes active/inactive. To use, this
class should be subclassed, and one or more of the following methods
overriden: publish
, nodeCreated
, or
nodeDeleted
.
Nested Class Summary |
Nested classes inherited from class ti.chimera.registry.NodeSubscriber |
NodeSubscriber.ScriptFunctionNodeSubscriber |
Nested classes inherited from class ti.chimera.registry.NodeCreationSubscriber |
NodeCreationSubscriber.ScriptFunctionNodeCreationSubscriber |
Nested classes inherited from class ti.chimera.registry.NodeDeletionSubscriber |
NodeDeletionSubscriber.ScriptFunctionNodeDeletionSubscriber |
Constructor Summary | |
Plugin.RegistrySubscriberResource(java.lang.String path,
NodeContract contract,
boolean managed)
Create a RegistrySubscriberResource , which
automatically handles subscribing/unsubscribing from registry
nodes. |
Method Summary | |
void |
install()
install the subscriber |
void |
nodeCreated(Node node)
Called when the node is created (ie. |
void |
nodeDeleted(Node node)
Called when the node is deleted (ie. |
void |
publish(Node node,
java.lang.Object value)
Called to publish the new node value to the subscriber. |
java.lang.String |
toString()
For debugging. |
void |
uninstall()
uninstall the subscriber |
Methods inherited from class ti.chimera.Resource |
isManaged |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Plugin.RegistrySubscriberResource(java.lang.String path, NodeContract contract, boolean managed)
RegistrySubscriberResource
, which
automatically handles subscribing/unsubscribing from registry
nodes.
path
- the path to (un)subscribe to/fromcontract
- the node-contract, or null
;
used for subscribeToValue
managed
- is this a managed resourceMethod Detail |
public void publish(Node node, java.lang.Object value)
publish
in interface NodeSubscriber
node
- the node doing the publishingvalue
- the node's new valuepublic void nodeCreated(Node node)
nodeCreated
in interface NodeCreationSubscriber
node
- the node createdpublic void nodeDeleted(Node node)
nodeDeleted
in interface NodeDeletionSubscriber
node
- the node deletedpublic void install()
install
in class Resource
Resource.uninstall()
public void uninstall()
uninstall
in class Resource
Resource.install()
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |