Module java.base
Package java.lang.classfile.instructionPREVIEW

# Interface ConstantInstruction.ArgumentConstantInstruction

All Superinterfaces:
  `ClassFileElementPREVIEW`, `CodeElementPREVIEW`, `ConstantInstructionPREVIEW`, `InstructionPREVIEW`

Enclosing interface:
  `ConstantInstructionPREVIEW`

public static sealed interface ConstantInstruction.ArgumentConstantInstruction extends ConstantInstructionPREVIEW
`ArgumentConstantInstruction` is a preview API of the Java platform.
Programs can only use `ArgumentConstantInstruction` when preview features are enabled.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.
Models an "argument constant" instruction (e.g., `bipush`).

Since:
  22

- ## Nested Class Summary

  ## Nested classes/interfaces declared in interface java.lang.classfile.instruction.ConstantInstructionPREVIEW

  `ConstantInstruction.ArgumentConstantInstructionPREVIEW, ConstantInstruction.IntrinsicConstantInstructionPREVIEW, ConstantInstruction.LoadConstantInstructionPREVIEW`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Integer`
  `constantValue()`
  Returns the constant value.
  `default TypeKindPREVIEW`
  `typeKind()`
  Returns the type of the constant.

  ### Methods declared in interface java.lang.classfile.InstructionPREVIEW

  `opcode, sizeInBytes`

- ## Method Details

  - ### constantValue

    Integer constantValue()
    Description copied from interface: `ConstantInstruction`
    Returns the constant value.
    Specified by:
      `constantValue` in interface `ConstantInstructionPREVIEW`
    Returns:
      the constant value

  - ### typeKind

    default TypeKindPREVIEW typeKind()
    Returns the type of the constant.
    Specified by:
      `typeKind` in interface `ConstantInstructionPREVIEW`
    Returns:
      the type of the constant