java.lang.Object
jakarta.enterprise.util.AnnotationLiteral<T>
- Type Parameters:
T
- the annotation type
- All Implemented Interfaces:
Serializable
,Annotation
- Direct Known Subclasses:
Alternative.Literal
,Any.Literal
,ApplicationMap.Literal
,ApplicationScoped.Literal
,AutoApplySession.Literal
,BasicAuthenticationMechanismDefinition.BasicAuthenticationMechanism.Literal
,BeforeDestroyed.Literal
,ConversationScoped.Literal
,CustomFormAuthenticationMechanismDefinition.CustomFormAuthenticationMechanism.Literal
,Default.Literal
,Dependent.Literal
,Destroyed.Literal
,FacesBehavior.Literal
,FacesConfig.Literal
,FacesConverter.Literal
,FacesDataModel.Literal
,FacesValidator.Literal
,FlowBuilderParameter.Literal
,FlowDefinition.Literal
,FlowMap.Literal
,FormAuthenticationMechanismDefinition.FormAuthenticationMechanism.Literal
,HeaderMap.Literal
,HeaderValuesMap.Literal
,Initialized.Literal
,InitParameterMap.Literal
,InjectLiteral
,LoginToContinue.Literal
,ManagedProperty.Literal
,NamedLiteral
,Nonbinding.Literal
,OpenIdAuthenticationMechanismDefinition.OpenIdAuthenticationMechanism.Literal
,Push.Literal
,QualifierLiteral
,RememberMe.Literal
,RequestCookieMap.Literal
,RequestMap.Literal
,RequestParameterMap.Literal
,RequestParameterValuesMap.Literal
,RequestScoped.Literal
,SessionMap.Literal
,SessionScoped.Literal
,SingletonLiteral
,Specializes.Literal
,TransientReference.Literal
,Typed.Literal
,Vetoed.Literal
,View.Literal
,ViewMap.Literal
,WebsocketEvent.Closed.Literal
,WebsocketEvent.Opened.Literal
public abstract class AnnotationLiteral<T extends Annotation>
extends Object
implements Annotation, Serializable
Supports inline instantiation of annotation type instances.
Reflection operations are using SecurityActions
utility class to support security manager.
An instance of an annotation type may be obtained by subclassing AnnotationLiteral
.
The subclass must implement the annotation interface to satisfy the Annotation
contract.
public abstract class PayByQualifier extends AnnotationLiteral<PayBy> implements PayBy { }
PayBy payByCheque = new PayByQualifier() { public PaymentMethod value() { return CHEQUE; } };
- See Also:
-
Constructor Summary
ModifierConstructorDescriptionprotected
The literal constructor, only for subclasses. -
Method Summary
-
Constructor Details
-
AnnotationLiteral
protected AnnotationLiteral()The literal constructor, only for subclasses.
-
-
Method Details
-
annotationType
- Specified by:
annotationType
in interfaceAnnotation
-
toString
- Specified by:
toString
in interfaceAnnotation
- Overrides:
toString
in classObject
-
equals
- Specified by:
equals
in interfaceAnnotation
- Overrides:
equals
in classObject
-
hashCode
public int hashCode()- Specified by:
hashCode
in interfaceAnnotation
- Overrides:
hashCode
in classObject
-