Package io.quarkus.gizmo
Interface Loop
-
- All Known Subinterfaces:
ForEachLoop,WhileLoop
- All Known Implementing Classes:
ForEachLoopImpl,LoopImpl,WhileLoopImpl
public interface LoopA loop construct.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description BytecodeCreatorblock()The block inside the loop.voiddoBreak(BytecodeCreator creator)Writes bytecode into the providedBytecodeCreatorto make it exit the loop, effectively issuing a Java 'break' statement.voiddoContinue(BytecodeCreator creator)Writes bytecode into the providedBytecodeCreatorto make it jump back to the start of the loop, effectively issuing a Java 'continue' statement.
-
-
-
Method Detail
-
block
BytecodeCreator block()
The block inside the loop.- Returns:
- the block
-
doContinue
void doContinue(BytecodeCreator creator)
Writes bytecode into the providedBytecodeCreatorto make it jump back to the start of the loop, effectively issuing a Java 'continue' statement. Generally this will be applied to a branch of an if statement.- Parameters:
creator- The creator that should return to the start of the loop
-
doBreak
void doBreak(BytecodeCreator creator)
Writes bytecode into the providedBytecodeCreatorto make it exit the loop, effectively issuing a Java 'break' statement. Generally this will be applied to a branch of an if statement.- Parameters:
creator- The creator that should break from the loop
-
-