public abstract class DoWhileFinallyMacro extends AbstractProofMacro
getProofMacro()
as long the given bound
of steps is not reached yet, the condition given by getCondition()
holds, and the macro is applicable. When this becomes false and the step bound
is not reached yet, the macro given by getAltProofMacro()
is applied.ProofMacro.ProgressBarListener
Constructor and Description |
---|
DoWhileFinallyMacro() |
Modifier and Type | Method and Description |
---|---|
ProofMacroFinishedInfo |
applyTo(UserInterfaceControl uic,
Proof proof,
ImmutableList<Goal> goals,
PosInOccurrence posInOcc,
ProverTaskListener listener)
Apply this macro on the given goals.
|
boolean |
canApplyTo(Proof proof,
ImmutableList<Goal> goals,
PosInOccurrence posInOcc)
Can this macro be applied on the given goals?
|
protected abstract ProofMacro |
getAltProofMacro()
Gets the alternative proof macro for the else-branch.
|
protected abstract boolean |
getCondition() |
java.lang.String |
getDescription()
Gets the description of this macro.
|
java.lang.String |
getName()
Gets the name of this macro.
|
protected abstract ProofMacro |
getProofMacro()
Gets the proof macro.
|
applyTo, canApplyTo, getMaxSteps, getScriptCommandName, hasParameter, resetParams, setParameter
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getCategory
public java.lang.String getName()
ProofMacro
null
constant stringpublic java.lang.String getDescription()
ProofMacro
null
constant stringpublic boolean canApplyTo(Proof proof, ImmutableList<Goal> goals, PosInOccurrence posInOcc)
ProofMacro
proof
- the current Proof
(not null
)goals
- the goals (not null
)posInOcc
- the position in occurrence (may be null
)true
, if the macro is allowed to be appliedpublic ProofMacroFinishedInfo applyTo(UserInterfaceControl uic, Proof proof, ImmutableList<Goal> goals, PosInOccurrence posInOcc, ProverTaskListener listener) throws java.lang.InterruptedException, java.lang.Exception
ProofMacro
InterruptedException
.
A ProverTaskListener
can be provided to which the progress will
be reported. If no reports are desired, null
cna be used for
this parameter. If more than one listener is needed, consider combining
them using a single listener object using the composite pattern.uic
- the UserInterfaceControl
to useproof
- the current Proof
(not null
)goals
- the goals (not null
)posInOcc
- the position in occurrence (may be null
)listener
- the listener to use for progress reports (may be
null
)java.lang.InterruptedException
- if the application of the macro has been interrupted.java.lang.Exception
protected abstract ProofMacro getProofMacro()
protected abstract ProofMacro getAltProofMacro()
protected abstract boolean getCondition()