Package dynaop

Examples of dynaop.Interceptor


        Mock methodInterceptorMock = mock(MethodInterceptor.class);

        pico.registerComponentInstance("interceptorComponentKey", methodInterceptorMock.proxy());

        InterceptorFactory interceptorFactory = new ContainerSuppliedInterceptorFactory(pico, "interceptorComponentKey");
        Interceptor interceptor = interceptorFactory.create(null);
        assertNotNull(interceptor);

        // verify that the dynaop interceptor delegates to the MethodInterceptor
        // in the container:
        methodInterceptorMock.expects(once()).method("invoke");
        interceptor.intercept(null);
    }
View Full Code Here

TOP

Related Classes of dynaop.Interceptor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.