Class ExecutionQueueModule
- All Implemented Interfaces:
IModule,ModuleElement,IEolModule
Dummy module intended to allow the reuse of a single
EpsilonDebugServer across multiple Epsilon programs. Users should
call the enqueue(IEolModule) method to add more programs to be
debugged, which will be executed in FIFO order.
The module will run indefinitely until it is terminated, running every enqueued module and waiting when all modules have been executed so far, until more modules are enqueued or execution is terminated.
The module can automatically attach the modules to be run to a given adapter,
if set via setDebugAdapter(EpsilonDebugAdapter).
This is recommended, as otherwise there is a risk that certain events will be
missed by the debug adapter (e.g. the pre-execute checks for the root of its AST).
The queue is polled according to a given interval, configured via
setPollInterval(Duration) (which should be measured at least
in milliseconds).
-
Field Summary
FieldsFields inherited from class org.eclipse.epsilon.eol.EolModule
context, declaredModelDeclarations, declaredOperations, imports, main, modelDeclarations, operations, postOperationStatementsFields inherited from class org.eclipse.epsilon.eol.AbstractModule
parseProblems, parser, sourceFile, sourceUri -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionenqueue(IEolModule module) Adds a module to the end of the queue of modules to be executed.voidsetDebugAdapter(EpsilonDebugAdapter debugAdapter) voidsetPollInterval(Duration pollInterval) Methods inherited from class org.eclipse.epsilon.eol.EolModule
adapt, build, clearCache, createDebugger, createLexer, createParser, execute, getContext, getDeclaredModelDeclarations, getDeclaredOperations, getImportConfiguration, getImportManager, getImports, getMain, getMainRule, getModelDeclarations, getOperations, getParentModule, getPostOperationStatements, loadImports, prepareContext, setContext, setImportManager, setMain, setParentModule, toStringMethods inherited from class org.eclipse.epsilon.eol.AbstractModule
assignAnnotations, assignComment, assignComments, createAst, extractComments, getParseProblems, getSourceFile, getSourceUri, invokeMainRule, parse, parseMethods inherited from class org.eclipse.epsilon.common.module.AbstractModuleElement
equals, getChildren, getComments, getData, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, hashCode, setModule, setParent, setRegion, setUriMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.epsilon.eol.IEolModule
configure, getConfigurationProperties, getParseProblems, parseMethods inherited from interface org.eclipse.epsilon.common.module.IModule
createAst, getSourceUri, parse, parse, parse, parse, parseMethods inherited from interface org.eclipse.epsilon.common.module.ModuleElement
getChildren, getComments, getData, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUri
-
Field Details
-
DEFAULT_DURATION
-
-
Constructor Details
-
ExecutionQueueModule
public ExecutionQueueModule()
-
-
Method Details
-
enqueue
Adds a module to the end of the queue of modules to be executed.- Returns:
- A
Futurewhich will eventually contain the execution result of the enqueued module.
-
executeImpl
- Overrides:
executeImplin classEolModule- Throws:
EolRuntimeException
-
getPollInterval
-
setPollInterval
-
getDebugAdapter
-
setDebugAdapter
-