public class TransformationAttribute extends Attribute implements Configurable, GTAttribute
executeTransformation()
method.NamedObj.ContainedObjectsIterator
Modifier and Type | Field and Description |
---|---|
Parameter |
condition
The condition under which this attribute is applicable.
|
TransformationAttributeEditorFactory |
editorFactory
The editor factory for the contents in this attribute (the model
updater).
|
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
Constructor and Description |
---|
TransformationAttribute(NamedObj container,
java.lang.String name)
Construct an attribute with the given name contained by the specified
entity.
|
TransformationAttribute(Workspace workspace)
Construct an attribute in the specified workspace with an empty
string as a name.
|
Modifier and Type | Method and Description |
---|---|
protected void |
_exportMoMLContents(java.io.Writer output,
int depth)
Write a MoML description of the contents of this object, which
in this base class is the attributes.
|
void |
addExecutionListener(ExecutionListener listener)
Add an execution listener to the list of execution listeners, which are
invoked at specific points when the transformation is executed.
|
java.lang.Object |
clone(Workspace workspace)
Clone the object into the specified workspace.
|
void |
configure(java.net.URL base,
java.lang.String source,
java.lang.String text)
Configure the object with data from the specified input source
(a URL) and/or textual data.
|
void |
executeTransformation()
Execute the transformation with the container of this attribute as the
model to be transformed.
|
void |
executeTransformation(CompositeEntity model)
Execute the transformation with the given model as the model to be
transformed.
|
java.lang.String |
getConfigureSource()
Return the input source that was specified the last time the configure
method was called.
|
java.lang.String |
getConfigureText()
Return the text string that represents the current configuration of
this object.
|
PteraModalModel |
getModelUpdater()
Get the model updater encapsulated in this attribute.
|
void |
removeExecutionListener(ExecutionListener listener)
Remove an execution listener from the list of execution listeners, which\
are invoked at specific points when the transformation is executed.
|
_checkContainer, _getContainedObject, _propagateExistence, getContainer, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, setContainer, setName, updateContent
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _description, _executeChangeRequests, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, _validateSettables, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, attributeDeleted, attributeList, attributeList, attributeTypeChanged, clone, containedObjectsIterator, decorators, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getElementName, getFullName, getModelErrorHandler, getName, getName, getPrototypeList, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, notifyOfNameChange, propagateExistence, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, uniqueName, validateSettables, workspace
public Parameter condition
public TransformationAttributeEditorFactory editorFactory
public TransformationAttribute(NamedObj container, java.lang.String name) throws NameDuplicationException, IllegalActionException
container
- The container.name
- The name of this attribute.IllegalActionException
- If the attribute is not of an
acceptable class for the container, or if the name contains a period.NameDuplicationException
- If the name coincides with
an attribute already in the container.public TransformationAttribute(Workspace workspace)
workspace
- The workspace that will list the attribute.public void addExecutionListener(ExecutionListener listener)
listener
- The listener.removeExecutionListener(ExecutionListener)
public java.lang.Object clone(Workspace workspace) throws java.lang.CloneNotSupportedException
clone
in class Attribute
workspace
- The workspace for the cloned object.java.lang.CloneNotSupportedException
- Not thrown in this base classNamedObj.exportMoML(Writer, int, String)
,
NamedObj.setDeferringChangeRequests(boolean)
public void configure(java.net.URL base, java.lang.String source, java.lang.String text) throws java.lang.Exception
This method is defined to throw a very general exception to allow classes that implement the interface to use whatever exceptions are appropriate.
configure
in interface Configurable
base
- The base relative to which references within the input
are found, or null if this is not known, or there is none.source
- The input source, which specifies a URL, or null
if none.text
- Configuration information given as text, or null if
none.java.lang.Exception
- If something goes wrong.public void executeTransformation() throws java.lang.Exception
java.lang.Exception
- If error occurs in the transformation.executeTransformation(CompositeEntity)
public void executeTransformation(CompositeEntity model) throws java.lang.Exception
model
- The model to be transformed.java.lang.Exception
- If error occurs in the transformation.public java.lang.String getConfigureSource()
getConfigureSource
in interface Configurable
public java.lang.String getConfigureText()
getConfigureText
in interface Configurable
public PteraModalModel getModelUpdater()
public void removeExecutionListener(ExecutionListener listener)
listener
- The listener to be removed.addExecutionListener(ExecutionListener)
protected void _exportMoMLContents(java.io.Writer output, int depth) throws java.io.IOException
_exportMoMLContents
in class NamedObj
output
- The output stream to write to.depth
- The depth in the hierarchy, to determine indenting.java.io.IOException
- If an I/O error occurs.NamedObj.exportMoML(Writer, int)