public abstract class AbstractSubmission extends java.lang.Object implements ISubmission
ISubmission
implementation that language extension
should extends.Modifier and Type | Class and Description |
---|---|
private class |
AbstractSubmission.LaunchMonitorJob
Job implementation that checks for launch life cycle.
|
Modifier and Type | Field and Description |
---|---|
private static java.lang.String |
JOB_NAME
Job name used for
AbstractSubmission.LaunchMonitorJob instances. |
protected static java.lang.String |
OUTPUT_PATH
Path of the output file for a given project.
|
private ISubmissionService |
service
ISubmissionService instance used by this submission. |
private ProblemSolver |
solver
Target problem solver this submission will work on.
|
Modifier | Constructor and Description |
---|---|
protected |
AbstractSubmission(ProblemSolver solver)
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
protected ISubmissionService |
getService()
Getter for the
ISubmissionService instance used by this submission. |
protected ProblemSolver |
getSolver()
Getter for the target problem solver.
|
protected void |
run(java.lang.String arguments,
org.eclipse.core.runtime.IProgressMonitor monitor)
Creates and runs a contextual
ISolverRunner with
the given arguments. |
private void |
startJob(ISolverRunner execution)
Starts a
AbstractSubmission.LaunchMonitorJob using the given launch. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getName, getOutput, start, submit
private static final java.lang.String JOB_NAME
AbstractSubmission.LaunchMonitorJob
instances.protected static final java.lang.String OUTPUT_PATH
private final ProblemSolver solver
private final ISubmissionService service
ISubmissionService
instance used by this submission.protected AbstractSubmission(ProblemSolver solver)
solver
- Target problem solver this submission will work on.protected final ProblemSolver getSolver()
solver
protected final void run(java.lang.String arguments, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException
ISolverRunner
with
the given arguments. Since solver should be ran
asynchronously, a monitoring job is started to check
execution life cycle.arguments
- Arguments to submit to the runner.monitor
- Monitor instance used for the solver execution.org.eclipse.core.runtime.CoreException
- If any error occurs while running solver instance.protected final ISubmissionService getService()
ISubmissionService
instance used by this submission.private final void startJob(ISolverRunner execution)
AbstractSubmission.LaunchMonitorJob
using the given launch.launch
- Target launch that will be monitored by created job.