Examples of LinkTool


Examples of org.apache.velocity.tools.view.tools.LinkTool

        Assert.assertEquals("/test/target?a=d", url);
    }

    public @Test void testNoIgnoreMultiple_WrongOrder()
    {
        LinkTool link = newLinkTool("a", new String[] { "a", "b", "c" });

        String url = link.setRelative("/target")
            .addAllParameters()
            .addQueryData("a", "d")
            .toString();

        Assert.assertEquals("/test/target?a=a&a=b&a=c&a=d", url);
View Full Code Here

Examples of org.apache.velocity.tools.view.tools.LinkTool

        assertTrue(context.get("map") instanceof HashMap<?,?>);
        assertTrue(context.get("date") instanceof DateTool);
        assertTrue(context.get("math") instanceof MathTool);

        assertTrue(context.get("link") instanceof LinkTool);
        LinkTool linkTool = (LinkTool) context.get("link");
        assertNotNull(linkTool.getContextURL());

        assertTrue(context.get("link2") instanceof LinkTool);
        LinkTool linkTool2 = (LinkTool) context.get("link2");
        assertNotNull(linkTool2.getContextURL());
      }
    };

    vv.setUrl(templateName);
    vv.setApplicationContext(wac);
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.