Interface NodeContext
public interface NodeContext
- Since:
- 8.0
-
Method Summary
Modifier and TypeMethodDescriptionvoid
dispatchScriptEvent
(String id, Object... params) Fires a script event of the given id, with the specified parameters.getId()
getPath()
Returns the full path of the node.Returns the property model of the node.boolean
isLeased()
Indicates whether the node is "leased", which means it has a heavy-weight subscription on it.boolean
isPropertyDynamic
(Property<?> prop) Indicates that the given property is bound or otherwise dynamic.<T> void
persistProperty
(Property<T> prop, T value) This requests that the given property value be saved persistently.void
save()
Requests that the system save the full local config of the node.
-
Method Details
-
getProviderContext
ProviderContext getProviderContext() -
getId
NodeId getId() -
getPath
TagPath getPath()Returns the full path of the node. -
getPropertyModel
BoundPropertySet getPropertyModel()Returns the property model of the node. -
getExpressionBindablePropertyModel
Optional<PropertyValueSource> getExpressionBindablePropertyModel() -
isLeased
boolean isLeased()Indicates whether the node is "leased", which means it has a heavy-weight subscription on it. In other words, the system knows that an entity is interested in receiving the fastest value changes possible. -
getExpressionParseContext
ExpressionParseContext getExpressionParseContext() -
dispatchScriptEvent
Fires a script event of the given id, with the specified parameters. This is the mechanism by which actors can contribute to the tag event script system. -
persistProperty
This requests that the given property value be saved persistently. It also has the side effect of inserting the property in the node configuration and synchronizing it across redundancy. Cannot be used for properties that are dynamic/bound. -
isPropertyDynamic
Indicates that the given property is bound or otherwise dynamic. This would mean that the property cannot be modified through writing or saved through the persistProperty call. Instead, it would need to be edited through other tag modification means. -
save
void save()Requests that the system save the full local config of the node.
-