Examples of Infrastructure


Examples of org.apache.tapestry.services.Infrastructure

    {
        IPage page = newMock(IPage.class);
        checkOrder(page, false);
       
        IRequestCycle cycle = newMock(IRequestCycle.class);
        Infrastructure infra = newMock(Infrastructure.class);
        IMarkupWriter writer = newBufferWriter();

        Location l = newLocation();

        RequestLocaleManager rlm = newMock(RequestLocaleManager.class);
        MarkupWriterSource mrs = newMock(MarkupWriterSource.class);
        WebResponse resp = newMock(WebResponse.class);
        AssetFactory assetFactory = newMock(AssetFactory.class);
        IEngineService pageService = newEngineService();

        List errorPages = new ArrayList();

        List parts = new ArrayList();
        parts.add("id1");

        PrintWriter pw = newPrintWriter();
       
        rlm.persistLocale();
        expect(cycle.getInfrastructure()).andReturn(infra).anyTimes();
        expect(infra.getOutputEncoding()).andReturn(("UTF-8")).anyTimes();
        expect(cycle.getParameters("updateParts")).andReturn((String[])parts.toArray(new String[parts.size()]));
        expect(resp.getPrintWriter(isA(ContentType.class))).andReturn(pw);
        expect(mrs.newMarkupWriter(eq(pw), isA(ContentType.class))).andReturn(writer);

        expect(cycle.getAttribute(TapestryUtils.PAGE_RENDER_SUPPORT_ATTRIBUTE)).andReturn(null);
View Full Code Here

Examples of org.apache.tapestry.services.Infrastructure

    public void test_Write_Body_Script()
    {
        MarkupFilter filter = new UTFMarkupFilter();
        PrintWriter writer = newPrintWriter();
        IRequestCycle cycle = newMock(IRequestCycle.class);
        Infrastructure inf = newMock(Infrastructure.class);

        replay();

        IMarkupWriter mw = new MarkupWriterImpl("text/html", writer, filter);
        DojoAjaxResponseBuilder builder = new DojoAjaxResponseBuilder(cycle, mw, null);

        String bscript = "var e=4;";
        String imageInit = "image initializations";
        String preload = "preloadedvarname";

        verify();

        expect(cycle.getInfrastructure()).andReturn(inf);
        expect(inf.getOutputEncoding()).andReturn("UTF-8");

        replay();

        builder.beginResponse();
        builder.beginBodyScript(mw, cycle);
View Full Code Here

Examples of org.springframework.data.neo4j.support.Infrastructure

    @Before
    public void setUp() throws Exception {
        // todo cleanup !!
        mappingContext = new Neo4jMappingContext();
        Infrastructure infrastructure = createInfrastructure(mappingContext);
        template = new Neo4jTemplate(infrastructure);
        conversionService = template.getConversionService();


        tx = template.getGraphDatabase().beginTx();
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.