public interface BRJSNode
extends org.bladerunnerjs.model.engine.Node
Modifier and Type | Method and Description |
---|---|
void |
addTemplateTransformations(java.util.Map<java.lang.String,java.lang.String> transformations)
Template transformation are used to replace aliases for namings that are automatically replaced when creating an node.
|
java.lang.String |
getTemplateName()
The method returns the name of the template, that is, the entity type and not the template group (which represents a collection
of templates).
|
void |
populate(java.lang.String templateGroup)
Any BRJSNode may be populated according to a pre-existing template.
|
BRJS |
root()
The method returns a
BRJS object that represents the root of the model. |
addObserver, addObserver, containsFile, create, delete, dir, dirExists, discoverAllChildren, exists, file, getObservers, getTypeName, incrementChildFileVersions, incrementFileVersion, memoizedScopeFiles, nodeProperties, notifyObservers, parentNode, ready, storageDir, storageFile
BRJS root()
BRJS
object that represents the root of the model.root
in interface org.bladerunnerjs.model.engine.Node
void populate(java.lang.String templateGroup) throws javax.naming.InvalidNameException, ModelUpdateException, TemplateInstallationException
templateGroup
- a String that represents the name by which the templates therein will be referenced when creating new nodes.
The templateGroup may contain templates for various BRJS entities, and the one corresponding to your current BRJSNode type
will be retrieved automatically.javax.naming.InvalidNameException
- if the node may not be created due to an invalid name associated to itTemplateInstallationException
- if the template has not been foundModelUpdateException
- for other non-BRJS-specific issuesjava.lang.String getTemplateName()
void addTemplateTransformations(java.util.Map<java.lang.String,java.lang.String> transformations) throws ModelUpdateException
transformations
- a Map of Strings to Strings where the key is the token and the value is the String it will be replaced with
* @see Custom TemplatesModelUpdateException
- for any exceptions thrown while calculating node template transformationsModelUpdateException
- for non-BRJS-specific exceptions