FileDocCategorySizeDatePackage
AroundInvokeHandler.javaAPI DocGlassfish v2 API4849Fri May 04 22:31:34 BST 2007com.sun.enterprise.deployment.annotation.handlers

AroundInvokeHandler

public class AroundInvokeHandler extends AbstractAttributeHandler
This handler is responsible for handling the javax.ejb.AroundInvoke attribute

Fields Summary
Constructors Summary
public AroundInvokeHandler()

    
Methods Summary
public java.lang.ClassgetAnnotationType()

return
the annoation type this annotation handler is handling

        return AroundInvoke.class;
    
private com.sun.enterprise.deployment.LifecycleCallbackDescriptorgetAroundInvokeDescriptor(com.sun.enterprise.deployment.annotation.AnnotationInfo ainfo)

        
        Method m = (Method) ainfo.getAnnotatedElement();
        LifecycleCallbackDescriptor lccDesc =
                new LifecycleCallbackDescriptor();
        lccDesc.setLifecycleCallbackClass(m.getDeclaringClass().getName());
        lccDesc.setLifecycleCallbackMethod(m.getName());
        return lccDesc;
    
public java.lang.Class[]getTypeDependencies()

return
an array of annotation types this annotation handler would require to be processed (if present) before it processes it's own annotation type.

        return getEjbAnnotationTypes();
    
protected booleanisDelegatee()

        return true;
    
protected com.sun.enterprise.deployment.annotation.HandlerProcessingResultprocessAnnotation(com.sun.enterprise.deployment.annotation.AnnotationInfo ainfo, com.sun.enterprise.deployment.annotation.context.EjbContext[] ejbContexts)


        for(EjbContext next : ejbContexts) {
            
            EjbDescriptor ejbDescriptor = 
                (EjbDescriptor) next.getDescriptor();

            ejbDescriptor.addAroundInvokeDescriptor(
                getAroundInvokeDescriptor(ainfo));
        }

        return getDefaultProcessedResult();
    
protected com.sun.enterprise.deployment.annotation.HandlerProcessingResultprocessAnnotation(com.sun.enterprise.deployment.annotation.AnnotationInfo ainfo, com.sun.enterprise.deployment.annotation.context.EjbInterceptorContext ejbInterceptorContext)


        EjbInterceptor ejbInterceptor =  ejbInterceptorContext.getDescriptor();

        ejbInterceptor.addAroundInvokeDescriptor(
            getAroundInvokeDescriptor(ainfo));
            
        return getDefaultProcessedResult();