Interface Attribute<A extends AttributePREVIEW<A>>
- Type Parameters:
A- the attribute type
- All Superinterfaces:
ClassFileElementPREVIEW,WritableElementPREVIEW<A>
- All Known Subinterfaces:
AnnotationDefaultAttributePREVIEW,BootstrapMethodsAttributePREVIEW,CharacterRangeTableAttributePREVIEW,CodeAttributePREVIEW,CompilationIDAttributePREVIEW,ConstantValueAttributePREVIEW,DeprecatedAttributePREVIEW,EnclosingMethodAttributePREVIEW,ExceptionsAttributePREVIEW,InnerClassesAttributePREVIEW,LineNumberTableAttributePREVIEW,LocalVariableTableAttributePREVIEW,LocalVariableTypeTableAttributePREVIEW,MethodParametersAttributePREVIEW,ModuleAttributePREVIEW,ModuleHashesAttributePREVIEW,ModuleMainClassAttributePREVIEW,ModulePackagesAttributePREVIEW,ModuleResolutionAttributePREVIEW,ModuleTargetAttributePREVIEW,NestHostAttributePREVIEW,NestMembersAttributePREVIEW,PermittedSubclassesAttributePREVIEW,RecordAttributePREVIEW,RuntimeInvisibleAnnotationsAttributePREVIEW,RuntimeInvisibleParameterAnnotationsAttributePREVIEW,RuntimeInvisibleTypeAnnotationsAttributePREVIEW,RuntimeVisibleAnnotationsAttributePREVIEW,RuntimeVisibleParameterAnnotationsAttributePREVIEW,RuntimeVisibleTypeAnnotationsAttributePREVIEW,SignatureAttributePREVIEW,SourceDebugExtensionAttributePREVIEW,SourceFileAttributePREVIEW,SourceIDAttributePREVIEW,StackMapTableAttributePREVIEW,SyntheticAttributePREVIEW,UnknownAttributePREVIEW
- All Known Implementing Classes:
CustomAttributePREVIEW
public sealed interface Attribute<A extends AttributePREVIEW<A>>
extends WritableElementPREVIEW<A>
permits AnnotationDefaultAttributePREVIEW, BootstrapMethodsAttributePREVIEW, CharacterRangeTableAttributePREVIEW, CodeAttributePREVIEW, CompilationIDAttributePREVIEW, ConstantValueAttributePREVIEW, DeprecatedAttributePREVIEW, EnclosingMethodAttributePREVIEW, ExceptionsAttributePREVIEW, InnerClassesAttributePREVIEW, LineNumberTableAttributePREVIEW, LocalVariableTableAttributePREVIEW, LocalVariableTypeTableAttributePREVIEW, MethodParametersAttributePREVIEW, ModuleAttributePREVIEW, ModuleHashesAttributePREVIEW, ModuleMainClassAttributePREVIEW, ModulePackagesAttributePREVIEW, ModuleResolutionAttributePREVIEW, ModuleTargetAttributePREVIEW, NestHostAttributePREVIEW, NestMembersAttributePREVIEW, PermittedSubclassesAttributePREVIEW, RecordAttributePREVIEW, RuntimeInvisibleAnnotationsAttributePREVIEW, RuntimeInvisibleParameterAnnotationsAttributePREVIEW, RuntimeInvisibleTypeAnnotationsAttributePREVIEW, RuntimeVisibleAnnotationsAttributePREVIEW, RuntimeVisibleParameterAnnotationsAttributePREVIEW, RuntimeVisibleTypeAnnotationsAttributePREVIEW, SignatureAttributePREVIEW, SourceDebugExtensionAttributePREVIEW, SourceFileAttributePREVIEW, SourceIDAttributePREVIEW, StackMapTableAttributePREVIEW, SyntheticAttributePREVIEW, UnknownAttributePREVIEW, CustomAttributePREVIEW<T> (not exhaustive)
Attribute is a preview API of the Java platform.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.
Models a classfile attribute 4.7. Many, though not all, subtypes of
AttributePREVIEW will implement
ClassElementPREVIEW, MethodElementPREVIEW, FieldElementPREVIEW, or CodeElementPREVIEW; attributes that
are also elements will be delivered when traversing the elements of the
corresponding model type. Additionally, all attributes are accessible
directly from the corresponding model type through AttributedElement.findAttribute(AttributeMapper)PREVIEW.-
Method Summary
Modifier and TypeMethodDescriptionReturns theAttributeMapperPREVIEW associated with this attribute.Returns the name of the attribute.Methods declared in interface java.lang.classfile.WritableElementPREVIEW
writeTo
-
Method Details
-
attributeName
-
attributeMapper
AttributeMapperPREVIEW<A> attributeMapper()Returns theAttributeMapperPREVIEW associated with this attribute.- Returns:
- the
AttributeMapperPREVIEW associated with this attribute
-
Attributewhen preview features are enabled.