Class SingletonHandler
- java.lang.Object
-
- com.sun.enterprise.deployment.annotation.handlers.AbstractHandler
-
- org.glassfish.ejb.deployment.annotation.handlers.AbstractEjbHandler
-
- org.glassfish.ejb.deployment.annotation.handlers.SingletonHandler
-
- All Implemented Interfaces:
org.glassfish.apf.AnnotationHandler
@Service public class SingletonHandler extends AbstractEjbHandler
This handler is responsible for handling the jakarta.ejb.Singleton- Author:
- Shing Wai Chan
-
-
Field Summary
-
Fields inherited from class org.glassfish.ejb.deployment.annotation.handlers.AbstractEjbHandler
localStrings
-
-
Constructor Summary
Constructors Constructor Description SingletonHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected EjbDescriptorcreateEjbDescriptor(String elementName, org.glassfish.apf.AnnotationInfo ainfo)Create a new EjbDescriptor for a given elementName and AnnotationInfo.protected StringgetAnnotatedName(Annotation annotation)Return the name attribute of given annotation.protected booleanisValidEjbDescriptor(EjbDescriptor ejbDesc, Annotation annotation)Check if the given EjbDescriptor matches the given Annotation.protected org.glassfish.apf.HandlerProcessingResultsetEjbDescriptorInfo(EjbDescriptor ejbDesc, org.glassfish.apf.AnnotationInfo ainfo)Set Annotation information to Descriptor.-
Methods inherited from class org.glassfish.ejb.deployment.annotation.handlers.AbstractEjbHandler
doDescriptionProcessing, doMappedNameProcessing, excludedFromImplementsClause, processAnnotation, setBusinessAndHomeInterfaces
-
Methods inherited from class com.sun.enterprise.deployment.annotation.handlers.AbstractHandler
getAnnotationType, getConnectorAnnotationTypes, getDefaultFailedResult, getDefaultProcessedResult, getEjbAndWebAnnotationTypes, getEjbAnnotationTypes, getInjectionMethodPropertyName, getInvalidAnnotatedElementHandlerResult, getOverallProcessingResult, getTypeDependencies, getWebAnnotationTypes, log, validateInjectionMethod
-
-
-
-
Method Detail
-
getAnnotatedName
protected String getAnnotatedName(Annotation annotation)
Return the name attribute of given annotation.- Specified by:
getAnnotatedNamein classAbstractEjbHandler- Parameters:
annotation-- Returns:
- name
-
isValidEjbDescriptor
protected boolean isValidEjbDescriptor(EjbDescriptor ejbDesc, Annotation annotation)
Check if the given EjbDescriptor matches the given Annotation.- Specified by:
isValidEjbDescriptorin classAbstractEjbHandler- Parameters:
ejbDesc-annotation-- Returns:
- boolean check for validity of EjbDescriptor
-
createEjbDescriptor
protected EjbDescriptor createEjbDescriptor(String elementName, org.glassfish.apf.AnnotationInfo ainfo) throws org.glassfish.apf.AnnotationProcessorException
Create a new EjbDescriptor for a given elementName and AnnotationInfo.- Specified by:
createEjbDescriptorin classAbstractEjbHandler- Parameters:
elementName-ainfo-- Returns:
- a new EjbDescriptor
- Throws:
org.glassfish.apf.AnnotationProcessorException
-
setEjbDescriptorInfo
protected org.glassfish.apf.HandlerProcessingResult setEjbDescriptorInfo(EjbDescriptor ejbDesc, org.glassfish.apf.AnnotationInfo ainfo) throws org.glassfish.apf.AnnotationProcessorException
Set Annotation information to Descriptor. This method will also be invoked for an existing descriptor with annotation as user may not specific a complete xml.- Specified by:
setEjbDescriptorInfoin classAbstractEjbHandler- Parameters:
ejbDesc-ainfo-- Returns:
- HandlerProcessingResult
- Throws:
org.glassfish.apf.AnnotationProcessorException
-
-