Package org.eclipse.epsilon.flock
Class FlockModule
- java.lang.Object
-
- org.eclipse.epsilon.common.module.AbstractModuleElement
-
- org.eclipse.epsilon.eol.AbstractModule
-
- org.eclipse.epsilon.eol.EolModule
-
- org.eclipse.epsilon.erl.ErlModule
-
- org.eclipse.epsilon.flock.FlockModule
-
- All Implemented Interfaces:
IModule
,ModuleElement
,IEolModule
,IErlModule
,IFlockModule
public class FlockModule extends ErlModule implements IFlockModule
-
-
Field Summary
Fields Modifier and Type Field Description protected MigrationStrategy
strategy
-
Fields inherited from class org.eclipse.epsilon.erl.ErlModule
declaredPost, declaredPre, post, pre
-
Fields inherited from class org.eclipse.epsilon.eol.EolModule
context, declaredModelDeclarations, declaredOperations, imports, main, modelDeclarations, operations, postOperationStatements
-
Fields inherited from class org.eclipse.epsilon.eol.AbstractModule
parseProblems, parser, sourceFile, sourceUri
-
-
Constructor Summary
Constructors Constructor Description FlockModule()
FlockModule(IFlockContext context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ModuleElement
adapt(AST cst, ModuleElement parentAst)
void
build(AST cst, IModule module)
protected org.antlr.runtime.Lexer
createLexer(org.antlr.runtime.ANTLRInputStream inputStream)
protected MigrationStrategy
createMigrationStrategy()
EpsilonParser
createParser(org.antlr.runtime.TokenStream tokenStream)
FlockResult
execute()
FlockResult
execute(IModel original, IModel migrated)
IFlockContext
getContext()
String
getMainRule()
MigrationStrategy
getStrategy()
protected FlockResult
processRules()
Main rule processing logic.-
Methods inherited from class org.eclipse.epsilon.erl.ErlModule
calculateSuperRules, execute, execute, executeImpl, getDeclaredPost, getDeclaredPre, getImportConfiguration, getPost, getPre, postExecution, prepareExecution
-
Methods inherited from class org.eclipse.epsilon.eol.EolModule
checkImports, clearCache, getDeclaredModelDeclarations, getDeclaredOperations, getImports, getImportsByExtension, getMain, getModelDeclarations, getOperations, getParentModule, getPostOperationStatements, prepareContext, setContext, setMain, setParentModule, toString
-
Methods inherited from class org.eclipse.epsilon.eol.AbstractModule
assignAnnotations, assignComment, assignComments, createAst, extractComments, getParseProblems, getSourceFile, getSourceUri, invokeMainRule, parse, parse
-
Methods inherited from class org.eclipse.epsilon.common.module.AbstractModuleElement
equals, getChildren, getComments, getData, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, hashCode, setModule, setParent, setRegion, setUri
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.eclipse.epsilon.eol.IEolModule
configure, getConfigurationProperties, getDeclaredModelDeclarations, getDeclaredOperations, getImports, getMain, getModelDeclarations, getOperations, getParentModule, getParseProblems, getPostOperationStatements, parse, setContext, setParentModule
-
Methods inherited from interface org.eclipse.epsilon.erl.IErlModule
getDeclaredPost, getDeclaredPre, getPost, getPre
-
Methods inherited from interface org.eclipse.epsilon.common.module.IModule
createAst, getSourceUri, parse, parse, parse, parse, parse
-
Methods inherited from interface org.eclipse.epsilon.common.module.ModuleElement
getChildren, getComments, getData, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUri
-
-
-
-
Field Detail
-
strategy
protected MigrationStrategy strategy
-
-
Constructor Detail
-
FlockModule
public FlockModule()
-
FlockModule
public FlockModule(IFlockContext context)
-
-
Method Detail
-
createLexer
protected org.antlr.runtime.Lexer createLexer(org.antlr.runtime.ANTLRInputStream inputStream)
- Overrides:
createLexer
in classErlModule
-
createParser
public EpsilonParser createParser(org.antlr.runtime.TokenStream tokenStream)
- Overrides:
createParser
in classErlModule
-
getMainRule
public String getMainRule()
- Overrides:
getMainRule
in classErlModule
-
adapt
public ModuleElement adapt(AST cst, ModuleElement parentAst)
-
build
public void build(AST cst, IModule module)
- Specified by:
build
in interfaceModuleElement
- Overrides:
build
in classErlModule
-
createMigrationStrategy
protected MigrationStrategy createMigrationStrategy()
-
execute
public FlockResult execute() throws EolRuntimeException
- Specified by:
execute
in interfaceIEolModule
- Overrides:
execute
in classEolModule
- Throws:
EolRuntimeException
-
execute
public FlockResult execute(IModel original, IModel migrated) throws EolRuntimeException
- Specified by:
execute
in interfaceIFlockModule
- Throws:
EolRuntimeException
-
processRules
protected FlockResult processRules() throws EolRuntimeException
Description copied from class:ErlModule
Main rule processing logic. Non-abstract for compatibility.- Overrides:
processRules
in classErlModule
- Returns:
- The result of executing this module.
- Throws:
EolRuntimeException
-
getStrategy
public MigrationStrategy getStrategy()
- Specified by:
getStrategy
in interfaceIFlockModule
- Returns:
-
getContext
public IFlockContext getContext()
- Specified by:
getContext
in interfaceIEolModule
- Specified by:
getContext
in interfaceIErlModule
- Specified by:
getContext
in interfaceIFlockModule
- Overrides:
getContext
in classErlModule
-
-