|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectAbstractAcceleoGenerator
org.eclipse.gmt.modisco.workflow.generator.GenerateDiscoverer
@Deprecated public class GenerateDiscoverer
Entry point of the 'GenerateDiscoverer' generation module.
Field Summary | |
---|---|
static java.lang.String |
MODULE_FILE_NAME
Deprecated. The name of the module. |
static java.lang.String[] |
TEMPLATE_NAMES
Deprecated. The name of the templates that are to be generated. |
Constructor Summary | |
---|---|
GenerateDiscoverer()
Deprecated. Allows the public constructor to be used. |
|
GenerateDiscoverer(URI modelURI,
java.io.File targetFolder,
java.util.List<? extends java.lang.Object> arguments)
Deprecated. This allows clients to instantiates a generator with all required information. |
Method Summary | |
---|---|
void |
doGenerate(Monitor monitor)
Deprecated. Launches the generation described by this instance. |
java.util.List<IAcceleoTextGenerationListener> |
getGenerationListeners()
Deprecated. If this generator needs to listen to text generation events, listeners can be returned from here. |
IAcceleoGenerationStrategy |
getGenerationStrategy()
Deprecated. If you need to change the way files are generated, this is your entry point. |
java.lang.String |
getModuleName()
Deprecated. This will be called in order to find and load the module that will be launched through this launcher. |
java.util.List<java.lang.String> |
getProperties()
Deprecated. If the module(s) called by this launcher require properties files, return their qualified path from here.Take note that the first added properties files will take precedence over subsequent ones if they contain conflicting keys. |
java.lang.String[] |
getTemplateNames()
Deprecated. This will be used to get the list of templates that are to be launched by this launcher. |
static void |
main(java.lang.String[] args)
Deprecated. This can be used to launch the generation from a standalone application. |
void |
registerPackages(ResourceSet resourceSet)
Deprecated. This can be used to update the resource set's package registry with all needed EPackages. |
void |
registerResourceFactories(ResourceSet resourceSet)
Deprecated. This can be used to update the resource set's resource factory registry with all needed factories. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String MODULE_FILE_NAME
public static final java.lang.String[] TEMPLATE_NAMES
Constructor Detail |
---|
public GenerateDiscoverer()
#initialize(EObject, File, List)
or
#initialize(URI, File, List)
is called.
The main reason for this constructor is to allow clients of this generation to call it from
another Java file, as it allows for the retrieval of getProperties()
and
getGenerationListeners()
.
public GenerateDiscoverer(URI modelURI, java.io.File targetFolder, java.util.List<? extends java.lang.Object> arguments) throws java.io.IOException
modelURI
- URI where the model on which this generator will be used is located.targetFolder
- This will be used as the output folder for this generation : it will be the base
path against which all file block URLs will be resolved.arguments
- If the template which will be called requires more than one argument taken from
the model, pass them here.
java.io.IOException
- This can be thrown in three scenarios : the module cannot be found, it cannot be
loaded, or the model cannot be loaded.Method Detail |
---|
public static void main(java.lang.String[] args)
args
- Arguments of the generation.public void doGenerate(Monitor monitor) throws java.io.IOException
monitor
- This will be used to display progress information to the user.
java.io.IOException
- This will be thrown if any of the output files cannot be saved to disk.public java.util.List<IAcceleoTextGenerationListener> getGenerationListeners()
public IAcceleoGenerationStrategy getGenerationStrategy()
The default is org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy
; it
generates files on the fly. If you only need to preview the results, return a new
org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy
. Both of these aren't
aware of the running Eclipse and can be used standalone.
If you need the file generation to be aware of the workspace (A typical example is when you
wanna override files that are under clear case or any other VCS that could forbid the
overriding), then return a new
org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy
. Note,
however, that this cannot be used standalone.
All three of these default strategies support merging through JMerge.
public java.lang.String getModuleName()
public java.util.List<java.lang.String> getProperties()
Properties need to be in source folders, the path that we expect to get as a result of this
call are of the form <package>.<properties file name without extension>. For example,
if you have a file named "messages.properties" in package "org.eclipse.acceleo.sample", the
path that needs be returned by a call to getProperties()
is
"org.eclipse.acceleo.sample.messages".
ResourceBundle.getBundle(String)
public java.lang.String[] getTemplateNames()
getModuleName()
.public void registerPackages(ResourceSet resourceSet)
resourceSet
- The resource set which registry has to be updated.public void registerResourceFactories(ResourceSet resourceSet)
resourceSet
- The resource set which registry has to be updated.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |