class MethodContext extends LocalContext
offset
classContext, compilationUnitContext, entries, surroundingContext
Constructor and Description |
---|
MethodContext(Context surrounding,
boolean isStatic,
Type methodReturnType)
Construct a method context.
|
Modifier and Type | Method and Description |
---|---|
void |
confirmMethodHasReturn()
Record fact that (non-void) method has at least one return.
|
boolean |
isStatic()
Is this method static?
|
boolean |
methodHasReturn()
Does this (non-void) method have at least one return?
|
Type |
methodReturnType()
Return the return type of this method.
|
void |
writeToStdOut(PrettyPrinter p)
Write the contents of this context to STDOUT.
|
nextOffset, offset
addEntry, addType, classContext, compilationUnitContext, definingType, lookup, lookupType, methodContext, names, surroundingContext
public boolean isStatic()
public void confirmMethodHasReturn()
public boolean methodHasReturn()
public Type methodReturnType()
public void writeToStdOut(PrettyPrinter p)
Context
writeToStdOut
in class LocalContext
p
- for pretty printing with indentation.