# Uses of Interface
java.lang.classfile.instruction.SwitchCase

Packages that use SwitchCase
Package
Description
java.lang.classfile
Provides classfile parsing, generation, and transformation library.
java.lang.classfile.instruction
Provides interfaces describing code instructions for the `java.lang.classfile` library.

- ## Uses of SwitchCase in java.lang.classfile

  Method parameters in java.lang.classfile with type arguments of type SwitchCase
  Modifier and Type
  Method
  Description
  `default CodeBuilder`
  CodeBuilder.`lookupswitch(Label defaultTarget, List<SwitchCase> cases)`
  Generates an instruction to access a jump table by key match and jump.
  `default CodeBuilder`
  CodeBuilder.`tableswitch(int low, int high, Label defaultTarget, List<SwitchCase> cases)`
  Generates an instruction to access a jump table by index and jump.
  `default CodeBuilder`
  CodeBuilder.`tableswitch(Label defaultTarget, List<SwitchCase> cases)`
  Generates an instruction to access a jump table by index and jump.

- ## Uses of SwitchCase in java.lang.classfile.instruction

  Methods in java.lang.classfile.instruction that return SwitchCase
  Modifier and Type
  Method
  Description
  `static SwitchCase`
  SwitchCase.`of(int caseValue, Label target)`
  Returns a new switch case.
  Methods in java.lang.classfile.instruction that return types with arguments of type SwitchCase
  Modifier and Type
  Method
  Description
  `List<SwitchCase>`
  LookupSwitchInstruction.`cases()`
  Returns the cases of the switch.
  `List<SwitchCase>`
  TableSwitchInstruction.`cases()`
  Returns the cases of the switch.
  Method parameters in java.lang.classfile.instruction with type arguments of type SwitchCase
  Modifier and Type
  Method
  Description
  `static LookupSwitchInstruction`
  LookupSwitchInstruction.`of(Label defaultTarget, List<SwitchCase> cases)`
  Returns a lookup switch instruction.
  `static TableSwitchInstruction`
  TableSwitchInstruction.`of(int lowValue, int highValue, Label defaultTarget, List<SwitchCase> cases)`
  Returns a table switch instruction.