|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgnu.bytecode.ExitableBlock
public class ExitableBlock
Support for code block that one may be exited. You may optionally exit with a value, and/or run intervening finally blocks.
Typical usage::
CodeAttr code = ...; Type retType = ...; // a Type or null ExitableBlock block = code.startExitableBlock(retType, true); ... ... block.exit() ...; // conditionally ... code.endExitableBlock();
The block.exit()
compiles to a transfer to the end
of the block
, executing any finally
-blocks
within the block that surround the call to exit
.
If the ExitableBlock
should leave a result on
the stack, then specify the type of the result as the retType
.
The block itself must push a result before calling
endExitableBlock
(unless code.reachableHere()
is false), and must also push a result before block.exit().
.
Method Summary | |
---|---|
void |
exit()
Exit this surrounding block, executing finally blocks as needed. |
Label |
exitIsGoto()
If an exit is simple, return the label for block end. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public void exit()
public Label exitIsGoto()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |