Package org.eclipse.m2m.atl.emftvm.ant
Class EMFTVMTask
- java.lang.Object
-
- org.apache.tools.ant.ProjectComponent
-
- org.apache.tools.ant.Task
-
- org.eclipse.m2m.atl.emftvm.ant.EMFTVMTask
-
- All Implemented Interfaces:
java.lang.Cloneable
- Direct Known Subclasses:
CompileTask,LoadModelTask,RegisterMetamodelTask,RunTask,SaveModelTask
public abstract class EMFTVMTask extends org.apache.tools.ant.TaskGeneral superclass for EMFTVM Ant tasks.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringRESOURCE_SETThe EMFTVMResourceSetreference from within Ant.
-
Constructor Summary
Constructors Constructor Description EMFTVMTask()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidexecute()MetamodelgetMetamodel(java.lang.String name)Returns the loaded metamodel with the givenModelgetModel(java.lang.String name)Returns the loaded model with the givenorg.eclipse.emf.ecore.resource.ResourceSetgetResourceSet()Returns theResourceSetobject for this project.protected abstract voidinnerExecute()Performs the actual execution.voidsetModel(java.lang.String name, Model model)Sets a reference to the model by name.-
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
-
-
-
-
Field Detail
-
RESOURCE_SET
public static final java.lang.String RESOURCE_SET
The EMFTVMResourceSetreference from within Ant.- See Also:
- Constant Field Values
-
-
Method Detail
-
getResourceSet
public org.eclipse.emf.ecore.resource.ResourceSet getResourceSet()
Returns theResourceSetobject for this project.- Returns:
- the
ResourceSetobject for this project.
-
getModel
public Model getModel(java.lang.String name)
Returns the loaded model with the givenname
.- Parameters:
name- the model name- Returns:
- the loaded model with the given
name
-
getMetamodel
public Metamodel getMetamodel(java.lang.String name)
Returns the loaded metamodel with the givenname
.- Parameters:
name- the metamodel name- Returns:
- the loaded metamodel with the given
name
-
setModel
public void setModel(java.lang.String name, Model model)Sets a reference to the model by name.- Parameters:
name- the model namemodel- the model
-
execute
public final void execute() throws org.apache.tools.ant.BuildException- Overrides:
executein classorg.apache.tools.ant.Task- Throws:
org.apache.tools.ant.BuildException
-
innerExecute
protected abstract void innerExecute() throws java.lang.ExceptionPerforms the actual execution.- Throws:
java.lang.Exception
-
-