# Uses of Enum Class
java.lang.classfile.TypeAnnotation.TargetType

Packages that use TypeAnnotation.TargetTypePREVIEW
Package
Description
java.lang.classfile
Provides classfile parsing, generation, and transformation library.

- ## Uses of TypeAnnotation.TargetTypePREVIEW in java.lang.classfilePREVIEW

  Methods in java.lang.classfilePREVIEW that return TypeAnnotation.TargetTypePREVIEW
  Modifier and Type
  Method
  Description
  `TypeAnnotation.TargetTypePREVIEW`
  TypeAnnotation.TargetInfo.`targetType()`
  Returns the type of the target.
  `static TypeAnnotation.TargetTypePREVIEW`
  TypeAnnotation.TargetType.`valueOf(String name)`
  Returns the enum constant of this class with the specified name.
  `static TypeAnnotation.TargetTypePREVIEW[]`
  TypeAnnotation.TargetType.`values()`
  Returns an array containing the constants of this enum class, in the order they are declared.
  Methods in java.lang.classfilePREVIEW with parameters of type TypeAnnotation.TargetTypePREVIEW
  Modifier and Type
  Method
  Description
  `static TypeAnnotation.EmptyTargetPREVIEW`
  TypeAnnotation.TargetInfo.`of(TypeAnnotation.TargetTypePREVIEW targetType)`
  Returns a target for annotations.
  `static TypeAnnotation.OffsetTargetPREVIEW`
  TypeAnnotation.TargetInfo.`ofOffset(TypeAnnotation.TargetTypePREVIEW targetType, LabelPREVIEW 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.TypeArgumentTargetPREVIEW`
  TypeAnnotation.TargetInfo.`ofTypeArgument(TypeAnnotation.TargetTypePREVIEW targetType, LabelPREVIEW 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.
  `static TypeAnnotation.TypeParameterTargetPREVIEW`
  TypeAnnotation.TargetInfo.`ofTypeParameter(TypeAnnotation.TargetTypePREVIEW targetType, int typeParameterIndex)`
  Returns a target for annotations on a class or method type parameter declaration.
  `static TypeAnnotation.TypeParameterBoundTargetPREVIEW`
  TypeAnnotation.TargetInfo.`ofTypeParameterBound(TypeAnnotation.TargetTypePREVIEW targetType, int typeParameterIndex, int boundIndex)`
  Returns a target for annotations on the i'th bound of the j'th type parameter declaration of a generic class, interface, method, or constructor.
  `static TypeAnnotation.LocalVarTargetPREVIEW`
  TypeAnnotation.TargetInfo.`ofVariable(TypeAnnotation.TargetTypePREVIEW targetType, List<TypeAnnotation.LocalVarTargetInfoPREVIEW> table)`
  Returns a target for annotations on the type in a local variable declaration, including a variable declared as a resource in a try-with-resources statement.