FileDocCategorySizeDatePackage
SJSASFactory.javaAPI DocGlassfish v2 API5415Fri May 04 22:31:32 BST 2007com.sun.enterprise.deployment.annotation.factory

SJSASFactory

public class SJSASFactory extends Factory
This factory is responsible for initializing a ready to use AnnotationProcessor.
author
Shing Wai Chan

Fields Summary
private static Set
annotationClassNames
private static com.sun.enterprise.deployment.annotation.impl.AnnotationProcessorImpl
systemProcessor
Constructors Summary
private SJSASFactory()


      
    
Methods Summary
public static com.sun.enterprise.deployment.annotation.AnnotationProcessorgetAnnotationProcessor()

        init();
        AnnotationProcessorImpl processor = 
            Factory.getDefaultAnnotationProcessor();
        processor.setDelegate(systemProcessor);
        return processor;
    
public static java.util.SetgetAnnotations()

        init();
        return (HashSet)((HashSet)annotationClassNames).clone();
    
private static com.sun.enterprise.deployment.annotation.AnnotationHandler[]getSystemAnnotationHandlers()

        return new AnnotationHandler[] {
                new DenyAllHandler(),
                new ApplicationExceptionHandler(),
                new AroundInvokeHandler(),
                new DeclareRolesHandler(),
                new EntityManagerFactoryReferenceHandler(),
                new EntityManagerFactoryReferencesHandler(),
                new EntityManagerReferenceHandler(),
                new EntityManagerReferencesHandler(),
                new ExcludeClassInterceptorsHandler(),
                new ExcludeDefaultInterceptorsHandler(),
                new EJBHandler(),
                new EJBsHandler(),
                new HandlerChainHandler(),                        
                new InitHandler(),
                new InterceptorsHandler(),
                new MessageDrivenHandler(),
                new PermitAllHandler(),
                new PostActivateHandler(),
                new PostConstructHandler(),
                new PreDestroyHandler(),
                new PrePassivateHandler(),
                new ResourceHandler(),
                new RolesAllowedHandler(),
                new ResourcesHandler(),
                new RemoveHandler(),
                new RunAsHandler(),
                new StatefulHandler(),
                new StatelessHandler(),
                new TimeoutHandler(),    
                new TransactionAttributeHandler(),
                new TransactionManagementHandler(),
                new WebServiceHandler(),
                new WebServiceProviderHandler(),
		new WebServiceRefHandler(),
		new WebServiceRefsHandler()
        };
    
public static com.sun.enterprise.deployment.annotation.AnnotationProcessorgetSystemAnnotationProcessor()

        return systemProcessor;
    
private static synchronized voidinit()

        if (systemProcessor == null) {
            // initialize our system annotation processor...            
            systemProcessor = new AnnotationProcessorImpl();
            for (AnnotationHandler anHandler : getSystemAnnotationHandlers()) {
                systemProcessor.pushAnnotationHandler(anHandler); 
                annotationClassNames.add("L" +
                    anHandler.getAnnotationType().getName().
                    replace('.", '/") + ";");
            }
        }