- All Superinterfaces:
BodyCreator
A creator for
switch statement and expression cases.
Each case must declare at least one case value before building the body of the case.-
Method Summary
Modifier and TypeMethodDescriptionvoidbody(Consumer<BlockCreator> builder) Build the body of this executable code.default voidof(int val) Add a constant for this case.default voidof(long val) Add a constant for this case.voidAdd a constant for this case.default voidAdd a constant for this case.default voidof(ConstantDesc val) Add a constant for this case.default voidAdd a constant for this case.
-
Method Details
-
of
Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
of
Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
of
Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
of
Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
of
default void of(int val) Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
of
default void of(long val) Add a constant for this case.- Parameters:
val- the case value to add (must not benull)
-
body
Description copied from interface:BodyCreatorBuild the body of this executable code.- Specified by:
bodyin interfaceBodyCreator- Parameters:
builder- the builder (must not benull)
-