Examples of PageRenderRequestParameters


Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        replay();

        ComponentEventLinkEncoderImpl linkEncoder = new ComponentEventLinkEncoderImpl(resolver, contextPathEncoder, ls,
                request, response, null, null, null, true);

        PageRenderRequestParameters parameters = linkEncoder.decodePageRenderRequest(request);

        assertNull(parameters);

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        replay();

        ComponentEventLinkEncoderImpl linkEncoder = new ComponentEventLinkEncoderImpl(resolver, contextPathEncoder, ls,
                request, null, null, null, null, true);

        PageRenderRequestParameters parameters = linkEncoder.decodePageRenderRequest(request);

        assertEquals(parameters.getLogicalPageName(), "index");
        assertArraysEqual(parameters.getActivationContext().toStrings(), "foo", "bar");
        assertFalse(parameters.isLoopback());

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        replay();

        ComponentEventLinkEncoderImpl linkEncoder = new ComponentEventLinkEncoderImpl(resolver, contextPathEncoder, ls,
                request, null, null, null, null, true);

        PageRenderRequestParameters parameters = linkEncoder.decodePageRenderRequest(request);

        assertEquals(parameters.getLogicalPageName(), "foo/bar");
        assertEquals(parameters.getActivationContext().getCount(), 0);
        assertFalse(parameters.isLoopback());

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        replay();

        ComponentEventLinkEncoderImpl linkEncoder = new ComponentEventLinkEncoderImpl(resolver, contextPathEncoder, ls,
                request, null, null, null, null, true);

        PageRenderRequestParameters parameters = linkEncoder.decodePageRenderRequest(request);

        assertEquals(parameters.getLogicalPageName(), "foo/bar");
        assertArraysEqual(parameters.getActivationContext().toStrings(), "zip", "zoom");
        assertTrue(parameters.isLoopback());

        verify();
    }
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        train_canonicalizePageName(resolver, pageName, pageName);

        train_collectPageActivationContext(collector, pageName, 3);

        EventContext pageActivationContext = new ArrayEventContext(typeCoercer, 3);
        PageRenderRequestParameters parameters = new PageRenderRequestParameters(pageName, pageActivationContext);

        expect(factory.createPageRenderLink(parameters)).andReturn(link);

        replay();
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        train_canonicalizePageName(resolver, pageName, canonical);

        if (!overrideContext)
            train_collectPageActivationContext(collector, canonical, context);

        PageRenderRequestParameters parameters =
                new PageRenderRequestParameters(canonical,
                                                new ArrayEventContext(typeCoercer, context));

        expect(factory.createPageRenderLink(parameters)).andReturn(link);

        listener.createdPageRenderLink(link);
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        final String pageName = this.resolver.resolvePageClassNameToPageName(pageClass.getName());

        final EventContext context = activationContext == null ? new EmptyEventContext() : new ArrayEventContext(
                this.typeCoercer, activationContext);

        this.handler.handle(new PageRenderRequestParameters(pageName, context, false));
    }
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

                .collectPageActivationContext(canonical);

        boolean loopback = canonical.equals(requestGlobals.getActivePageName())
                && pageCache.get(pageName).hasResetListeners();

        PageRenderRequestParameters parameters = new PageRenderRequestParameters(canonical, new ArrayEventContext(
                typeCoercer, context), loopback);

        Link link = linkEncoder.createPageRenderLink(parameters);

        for (LinkCreationListener2 listener : listeners)
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        ComponentEventLinkEncoder encoder = new ComponentEventLinkEncoderImpl(null, null, null, request, response,
                                                                              manager, optimizer, null, null, null,
                                                                              false);

        PageRenderRequestParameters parameters = new PageRenderRequestParameters("MyPage", new EmptyEventContext());

        Link link = encoder.createPageRenderLink(parameters);

        assertEquals(link.toAbsoluteURI(), "MAGIC");
View Full Code Here

Examples of org.apache.tapestry5.services.PageRenderRequestParameters

        if (localeSpecified)
            localizationSetter.setLocaleFromLocaleName(possibleLocaleName);

        boolean isLoopback = request.getParameter(TapestryConstants.PAGE_LOOPBACK_PARAMETER_NAME) != null;

        return new PageRenderRequestParameters("View", new ArrayEventContext(typeCoercer, split[pacx]), isLoopback);
    }
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.