public class DefaultRuntimePropertiesPluginImpl extends Object implements org.azyva.dragom.execcontext.plugin.RuntimePropertiesPlugin
RuntimePropertiesPlugin considers the
following sources for the properties, in precedence order (the first one that
provides a requested property is used):
ExecContext
(ExecContext.getTransientData(java.lang.String)) having the prefix "runtime-property"
ToolLifeCycleExecContext.getToolProperty(java.lang.String)) having
the prefix "runtime-property", if the ExecContext implements
ToolLifeCycleExecContext
ExecContext.getProperty(java.lang.String)) having the prefix
"runtime-property"
ExecContext.getInitProperty(java.lang.String)) having the prefix "runtime-property"
Node properties within the Model (@link Node#getProperty}.
org.azyva.dragom.runtime-property.Domain1.app-a.MY_PROPERTY=my-value
defines a property MY_PROPERTY associated with the module Domain1/app-a whose value is my-value.
Property inheritance is considered, meaning that a property defined for a parent Node is used if the property is not defined specifically for the specified Node. For all sources except the Model this is done by sequentially removing Node's from the end of the NodePath. For the Model, this is automatically done by the fact that the property is requested on the Node specified by the Node.
A property being defined only for a specific Node is not explicitly supported, also the Model may support this.
Properties are always set as transient data
(ExecContext.setTransientData(java.lang.String, java.lang.Object)).
| Constructor and Description |
|---|
DefaultRuntimePropertiesPluginImpl(org.azyva.dragom.execcontext.ExecContext execContext) |
| Modifier and Type | Method and Description |
|---|---|
String |
getProperty(org.azyva.dragom.model.Node node,
String name) |
void |
setProperty(org.azyva.dragom.model.Node node,
String name,
String value) |
public DefaultRuntimePropertiesPluginImpl(org.azyva.dragom.execcontext.ExecContext execContext)
Copyright © 2015–2016 AZYVA INC.. All rights reserved.