インタフェースTableSwitchInstruction
- すべてのスーパー・インタフェース:
ClassFileElementPREVIEW
,CodeElementPREVIEW
,InstructionPREVIEW
public sealed interface TableSwitchInstruction extends InstructionPREVIEW
TableSwitchInstruction
は、JavaプラットフォームのプレビューAPIです。
プレビュー機能は、今後のリリースで削除するか、Javaプラットフォームの永続機能にアップグレードすることができます。
Code
属性のcode
配列内のtableswitch
命令をモデル化します。 CodeModel
PREVIEWの要素をトラバースするときに、CodeElement
PREVIEWとして提供されます。 - 導入されたバージョン:
- 22
-
メソッドのサマリー
インタフェースjava.lang.classfile.InstructionPREVIEWで宣言されたメソッド
opcode, sizeInBytes
-
メソッドの詳細
-
lowValue
int lowValue()スイッチのターゲット範囲の下限値(包含)を返します。- 戻り値:
- スイッチのターゲット範囲の下限値(包含)
-
highValue
int highValue()スイッチのターゲット範囲の上限値(包含)を返します。- 戻り値:
- スイッチのターゲット範囲の上限値(包含)
-
defaultTarget
-
cases
-
of
static TableSwitchInstructionPREVIEW of(int lowValue, int highValue, LabelPREVIEW defaultTarget, List<SwitchCasePREVIEW> cases) 表スイッチ命令を返します。- パラメータ:
lowValue
- スイッチのターゲット範囲の下限値(包含)highValue
- スイッチのターゲット範囲の上限値(包含)defaultTarget
- スイッチのデフォルトのターゲットcases
- スイッチのケース- 戻り値:
- 表スイッチ命令
-
TableSwitchInstruction
を使用できます。