Examples of ProxyCreator


Examples of com.google.gwt.user.rebind.rpc.ProxyCreator

    /** Test createProxyCreator() for an annotated class. */
    @Test public void testCreateProxyCreatorAnnotated() {
        XsrfRpcProxyGenerator generator = new XsrfRpcProxyGenerator();
        JClassType remoteService = mock(JClassType.class);
        when(remoteService.isAnnotationPresent(XsrfProtect.class)).thenReturn(true);
        ProxyCreator creator = generator.createProxyCreator(remoteService);
        assertTrue(creator instanceof XsrfRpcProxyCreator);
    }
View Full Code Here

Examples of com.google.gwt.user.rebind.rpc.ProxyCreator

    /** Test createProxyCreator() for a class that's not annotated. */
    @Test public void testCreateProxyCreatorNotAnnotated() {
        XsrfRpcProxyGenerator generator = new XsrfRpcProxyGenerator();
        JClassType remoteService = mock(JClassType.class);
        when(remoteService.isAnnotationPresent(XsrfProtect.class)).thenReturn(false);
        ProxyCreator creator = generator.createProxyCreator(remoteService);
        assertTrue(creator instanceof XsrfRpcProxyCreator)// decision is down in creator itself
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.