# Uses of Interface
java.lang.classfile.Label

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

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

  Methods in java.lang.classfile that return Label
  Modifier and Type
  Method
  Description
  `Label`
  CodeBuilder.BlockCodeBuilder.`breakLabel()`
  Returns the label locating where control is passed back to the parent block.
  `Label`
  CodeBuilder.`endLabel()`
  Returns the label associated with the end of the current block.
  `Label`
  TypeAnnotation.LocalVarTargetInfo.`endLabel()`
  The given local variable has a value at indices into the code array in the interval [start_pc, start_pc + length), that is, between start_pc inclusive and start_pc + length exclusive.
  `default Label`
  CodeBuilder.`newBoundLabel()`
  Creates a new label bound at the current position.
  `Label`
  CodeBuilder.`newLabel()`
  Returns a fresh unbound label.
  `Label`
  CodeBuilder.`startLabel()`
  Returns the label associated with the beginning of the current block.
  `Label`
  TypeAnnotation.LocalVarTargetInfo.`startLabel()`
  The given local variable has a value at indices into the code array in the interval [start_pc, start_pc + length), that is, between start_pc inclusive and start_pc + length exclusive.
  `Label`
  TypeAnnotation.OffsetTarget.`target()`
  The label right before the `Instruction` corresponding to the instanceof expression, the new expression, or the method reference expression.
  `Label`
  TypeAnnotation.TypeArgumentTarget.`target()`
  The label right before the `Instruction` corresponding to the cast expression, the new expression, the explicit constructor invocation statement, the method invocation expression, or the method reference expression.
  Methods in java.lang.classfile with parameters of type Label
  Modifier and Type
  Method
  Description
  `default CodeBuilder`
  CodeBuilder.`branch(Opcode op, Label target)`
  Generates a branch instruction.
  `default CodeBuilder`
  CodeBuilder.`characterRange(Label startScope, Label endScope, int characterRangeStart, int characterRangeEnd, int flags)`
  Declares a character range entry.
  `default CodeBuilder`
  CodeBuilder.`exceptionCatch(Label start, Label end, Label handler, ClassEntry catchType)`
  Declares an exception table entry.
  `default CodeBuilder`
  CodeBuilder.`exceptionCatch(Label start, Label end, Label handler, ClassDesc catchType)`
  Declares an exception table entry.
  `default CodeBuilder`
  CodeBuilder.`exceptionCatch(Label start, Label end, Label handler, Optional<ClassEntry> catchType)`
  Declares an exception table entry.
  `default CodeBuilder`
  CodeBuilder.`exceptionCatchAll(Label start, Label end, Label handler)`
  Declares an exception table entry catching all exceptions and errors.
  `default CodeBuilder`
  CodeBuilder.`goto_(Label target)`
  Generates an instruction to branch always.
  `default CodeBuilder`
  CodeBuilder.`goto_w(Label target)`
  Generates an instruction to branch always with wide index.
  `default CodeBuilder`
  CodeBuilder.`if_acmpeq(Label target)`
  Generates an instruction to branch if `reference` comparison `operand1 == operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_acmpne(Label target)`
  Generates an instruction to branch if `reference` comparison `operand1 != operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmpeq(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 == operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmpge(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 >= operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmpgt(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 > operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmple(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 <= operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmplt(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 < operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`if_icmpne(Label target)`
  Generates an instruction to branch if `int` comparison `operand1 != operand2` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifeq(Label target)`
  Generates an instruction to branch if `int` comparison with zero `== 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifge(Label target)`
  Generates an instruction to branch if `int` comparison with zero `>= 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifgt(Label target)`
  Generates an instruction to branch if `int` comparison with zero `> 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifle(Label target)`
  Generates an instruction to branch if `int` comparison with zero `<= 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`iflt(Label target)`
  Generates an instruction to branch if `int` comparison with zero `< 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifne(Label target)`
  Generates an instruction to branch if `int` comparison with zero `!= 0` succeeds.
  `default CodeBuilder`
  CodeBuilder.`ifnonnull(Label target)`
  Generates an instruction to branch if `reference` is not `null`.
  `default CodeBuilder`
  CodeBuilder.`ifnull(Label target)`
  Generates an instruction to branch if `reference` is `null`.
  `default CodeBuilder`
  CodeBuilder.`labelBinding(Label label)`
  Binds a label to the current position.
  `default CodeBuilder`
  CodeBuilder.`localVariable(int slot, Utf8Entry nameEntry, Utf8Entry descriptorEntry, Label startScope, Label endScope)`
  Declares a local variable entry.
  `default CodeBuilder`
  CodeBuilder.`localVariable(int slot, String name, ClassDesc descriptor, Label startScope, Label endScope)`
  Declares a local variable entry.
  `default CodeBuilder`
  CodeBuilder.`localVariableType(int slot, Utf8Entry nameEntry, Utf8Entry signatureEntry, Label startScope, Label endScope)`
  Declares a local variable type entry.
  `default CodeBuilder`
  CodeBuilder.`localVariableType(int slot, String name, Signature signature, Label startScope, Label endScope)`
  Declares a local variable type entry.
  `default CodeBuilder`
  CodeBuilder.`lookupswitch(Label defaultTarget, List<SwitchCase> cases)`
  Generates an instruction to access a jump table by key match and jump.
  `static TypeAnnotation.LocalVarTargetInfo`
  TypeAnnotation.LocalVarTargetInfo.`of(Label startLabel, Label endLabel, int index)`
  Returns local variable target info.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofCastExpr(Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type in a cast expression.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofConstructorInvocationTypeArgument(Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type argument in the explicit type argument list for an explicit constructor invocation statement.
  `static TypeAnnotation.OffsetTarget`
  TypeAnnotation.TargetInfo.`ofConstructorReference(Label target)`
  Returns a target for annotations on the type before the :: in a constructor reference expression.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofConstructorReferenceTypeArgument(Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type argument in the explicit type argument list for a new expression.
  `static TypeAnnotation.OffsetTarget`
  TypeAnnotation.TargetInfo.`ofInstanceofExpr(Label target)`
  Returns a target for annotations on the type in an instanceof expression.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofMethodInvocationTypeArgument(Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type argument in the explicit type argument list for a method invocation expression.
  `static TypeAnnotation.OffsetTarget`
  TypeAnnotation.TargetInfo.`ofMethodReference(Label target)`
  Returns a target for annotations on the type before the :: in a method reference expression.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofMethodReferenceTypeArgument(Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type argument in the explicit type argument list for a method reference expression.
  `static TypeAnnotation.OffsetTarget`
  TypeAnnotation.TargetInfo.`ofNewExpr(Label target)`
  Returns a target for annotations on the type in a new expression.
  `static TypeAnnotation.OffsetTarget`
  TypeAnnotation.TargetInfo.`ofOffset(TypeAnnotation.TargetType targetType, Label target)`
  Returns a target for annotations on the type in an instanceof expression or a new expression, or the type before the :: in a method reference expression.
  `static TypeAnnotation.TypeArgumentTarget`
  TypeAnnotation.TargetInfo.`ofTypeArgument(TypeAnnotation.TargetType targetType, Label target, int typeArgumentIndex)`
  Returns a target for annotations on the i'th type in a cast expression, or on the i'th type argument in the explicit type argument list for any of the following: a new expression, an explicit constructor invocation statement, a method invocation expression, or a method reference expression.
  `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 Label in java.lang.classfile.attribute

  Methods in java.lang.classfile.attribute that return Label
  Modifier and Type
  Method
  Description
  `Label`
  StackMapFrameInfo.UninitializedVerificationTypeInfo.`newTarget()`
  Returns the label immediately before the `new` instruction that creates this uninitialized object.
  `Label`
  StackMapFrameInfo.`target()`
  Returns the frame target label.
  Methods in java.lang.classfile.attribute with parameters of type Label
  Modifier and Type
  Method
  Description
  `int`
  CodeAttribute.`labelToBci(Label label)`
  Returns the position of the `label` in the `codeArray`.
  `static StackMapFrameInfo`
  StackMapFrameInfo.`of(Label target, List<StackMapFrameInfo.VerificationTypeInfo> locals, List<StackMapFrameInfo.VerificationTypeInfo> stack)`
  Returns a new stack map frame.
  `static StackMapFrameInfo.UninitializedVerificationTypeInfo`
  StackMapFrameInfo.UninitializedVerificationTypeInfo.`of(Label newTarget)`
  Returns an uninitialized verification type info.

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

  Methods in java.lang.classfile.instruction that return Label
  Modifier and Type
  Method
  Description
  `Label`
  LookupSwitchInstruction.`defaultTarget()`
  Returns the target of the default case.
  `Label`
  TableSwitchInstruction.`defaultTarget()`
  Returns the default target of the switch.
  `Label`
  CharacterRange.`endScope()`
  Returns the end of the instruction range.
  `Label`
  LocalVariable.`endScope()`
  Returns the end range of the local variable scope.
  `Label`
  LocalVariableType.`endScope()`
  Returns the end range of the local variable scope.
  `Label`
  ExceptionCatch.`handler()`
  Returns the handler for the exception.
  `Label`
  LabelTarget.`label()`
  Returns the label corresponding to this target.
  `Label`
  CharacterRange.`startScope()`
  Returns the start of the instruction range.
  `Label`
  LocalVariable.`startScope()`
  Returns the start range of the local variable scope.
  `Label`
  LocalVariableType.`startScope()`
  Returns the start range of the local variable scope.
  `Label`
  BranchInstruction.`target()`
  Returns the branch target of this instruction.
  `Label`
  DiscontinuedInstruction.JsrInstruction.`target()`
  Returns the target of the jump subroutine instruction.
  `Label`
  SwitchCase.`target()`
  Returns the branch target corresponding to this case.
  `Label`
  ExceptionCatch.`tryEnd()`
  Returns the end of the instruction range for the guarded instructions.
  `Label`
  ExceptionCatch.`tryStart()`
  Returns the beginning of the instruction range for the guarded instructions.
  Methods in java.lang.classfile.instruction with parameters of type Label
  Modifier and Type
  Method
  Description
  `static BranchInstruction`
  BranchInstruction.`of(Opcode op, Label target)`
  Returns a branch instruction.
  `static CharacterRange`
  CharacterRange.`of(Label startScope, Label endScope, int characterRangeStart, int characterRangeEnd, int flags)`
  Returns a character range pseudo-instruction.
  `static DiscontinuedInstruction.JsrInstruction`
  DiscontinuedInstruction.JsrInstruction.`of(Label target)`
  Returns a jump subroutine instruction.
  `static DiscontinuedInstruction.JsrInstruction`
  DiscontinuedInstruction.JsrInstruction.`of(Opcode op, Label target)`
  Returns a jump subroutine instruction.
  `static ExceptionCatch`
  ExceptionCatch.`of(Label handler, Label tryStart, Label tryEnd)`
  Returns an exception table pseudo-instruction to catch everything.
  `static ExceptionCatch`
  ExceptionCatch.`of(Label handler, Label tryStart, Label tryEnd, Optional<ClassEntry> catchTypeEntry)`
  Returns an exception table pseudo-instruction.
  `static LocalVariable`
  LocalVariable.`of(int slot, Utf8Entry nameEntry, Utf8Entry descriptorEntry, Label startScope, Label endScope)`
  Returns a local variable pseudo-instruction.
  `static LocalVariable`
  LocalVariable.`of(int slot, String name, ClassDesc descriptor, Label startScope, Label endScope)`
  Returns a local variable pseudo-instruction.
  `static LocalVariableType`
  LocalVariableType.`of(int slot, Utf8Entry nameEntry, Utf8Entry signatureEntry, Label startScope, Label endScope)`
  Returns a local variable type pseudo-instruction.
  `static LocalVariableType`
  LocalVariableType.`of(int slot, String name, Signature signature, Label startScope, Label endScope)`
  Returns a local variable type pseudo-instruction.
  `static LookupSwitchInstruction`
  LookupSwitchInstruction.`of(Label defaultTarget, List<SwitchCase> cases)`
  Returns a lookup switch instruction.
  `static SwitchCase`
  SwitchCase.`of(int caseValue, Label target)`
  Returns a new switch case.
  `static TableSwitchInstruction`
  TableSwitchInstruction.`of(int lowValue, int highValue, Label defaultTarget, List<SwitchCase> cases)`
  Returns a table switch instruction.