public interface Goal
Pass
is run. It keeps trying until it is successful or
it fails and the compiler quits with an error.Modifier and Type | Field and Description |
---|---|
static int |
ATTEMPTED |
static int |
REACHED |
static int |
RUNNING |
static int |
UNREACHABLE |
static int |
UNREACHABLE_THIS_RUN |
static int |
UNREACHED |
Modifier and Type | Method and Description |
---|---|
void |
addCorequisiteGoal(Goal g,
Scheduler scheduler)
Add a new corequisite subgoal
g . |
void |
addPrerequisiteGoal(Goal g,
Scheduler scheduler)
Add a new subgoal
g . |
boolean |
conflictsWith(Goal goal)
Return true if this goal conflicts with the other; that is passes running
over both goals could access the same data.
|
java.util.Collection<Goal> |
corequisiteGoals(Scheduler scheduler)
Goals on which this goal may mutually depend.
|
Pass |
createPass(ExtensionInfo extInfo)
Create a pass that will attempt to reach the goal.
|
boolean |
hasBeenReached()
Return true if this goal has been reached.
|
boolean |
isReachable()
Return true if this goal is reachable.
|
Job |
job()
Get the job associated with this goal, or null.
|
java.lang.String |
name()
Get the name of the goal for debugging.
|
java.util.Collection<Goal> |
prerequisiteGoals(Scheduler scheduler)
Goals that must be completed before attempting this goal.
|
void |
setState(int state) |
void |
setUnreachable()
Set a flag indicating that this rule is unreachable.
|
void |
setUnreachableThisRun()
Mark the goal as reached or not reached.
|
int |
state() |
static final int UNREACHABLE
static final int UNREACHABLE_THIS_RUN
static final int UNREACHED
static final int ATTEMPTED
static final int REACHED
static final int RUNNING
boolean conflictsWith(Goal goal)
Pass createPass(ExtensionInfo extInfo)
java.util.Collection<Goal> corequisiteGoals(Scheduler scheduler)
java.util.Collection<Goal> prerequisiteGoals(Scheduler scheduler)
void addCorequisiteGoal(Goal g, Scheduler scheduler)
g
. g
is a
goal on which this goal mutually depends. The caller must be careful
to ensure that all corequisite goals can be eventually reached.
g
should be interned.void addPrerequisiteGoal(Goal g, Scheduler scheduler) throws CyclicDependencyException
g
. g
must be completed
before this goal is attempted. g
should be interned.CyclicDependencyException
- if a prerequisite of g
is this
boolean isReachable()
void setUnreachable()
void setUnreachableThisRun()
void setState(int state)
int state()
boolean hasBeenReached()
Job job()
java.lang.String name()