|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jmlspecs.jml4.rac.VariableGenerator
public abstract class VariableGenerator
A class for generating various unique variable names for RAC.
Constructor Summary | |
---|---|
VariableGenerator()
|
Method Summary | |
---|---|
abstract java.lang.String |
currentStackVar()
|
static VariableGenerator |
forClass()
Return a variable generator for classes |
static VariableGenerator |
forMethod(VariableGenerator varGen)
Return a variable generator for methods |
abstract java.lang.String |
freshCatchVar()
Return a fresh variable name for use in a catch clause. |
abstract java.lang.String |
freshOldVar()
Return a fresh variable name for storing the result of an old expression or an old variable. |
abstract java.lang.String |
freshPostVar()
Return a fresh variable name for storing the result of evaluating a specification case of a precondition. |
abstract java.lang.String |
freshPreVar()
Return a fresh variable name for storing the result of evaluating a specification case of a precondition. |
abstract java.lang.String |
freshStackVar()
Return a fresh variable name for a stack for use as saving to and restoring from pre-state values for potential recursive method calls. |
abstract java.lang.String |
freshVar()
Return a fresh variable name unique in the method. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public VariableGenerator()
Method Detail |
---|
public static VariableGenerator forClass()
public static VariableGenerator forMethod(VariableGenerator varGen)
varGen
- Variable generator for classespublic abstract java.lang.String freshOldVar()
VN_OLD_VAR +
n
, where n
is a unique number.
RacConstants.VN_OLD_VAR
public abstract java.lang.String freshPreVar()
VN_PRE_VAR +
n
, where n
is a unique number.
RacConstants.VN_PRE_VAR
public abstract java.lang.String freshPostVar()
VN_POST_VAR +
n
, where n
is a unique number.
RacConstants.VN_POST_VAR
public abstract java.lang.String freshStackVar()
VN_STACK_VAR +
n
, where n
is a unique number.
RacConstants.VN_STACK_VAR
public abstract java.lang.String currentStackVar()
public abstract java.lang.String freshVar()
VN_FREE_VAR + n
,
where n
is a unique number.
RacConstants.VN_FREE_VAR
public abstract java.lang.String freshCatchVar()
VN_CATCH_VAR + n
, where n
is
a unique number.
RacConstants.VN_FREE_VAR
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |