Package com.volantis.mcs.protocols

Examples of com.volantis.mcs.protocols.TestDOMOutputBuffer.appendEncoded()


     * Tests the retrieval of a menu as a menu item for displaying
     */
    public void testGetAsMenuItem() {
        // Setup a label
        DOMOutputBuffer buffer = new TestDOMOutputBuffer();
        buffer.appendEncoded("test");
        ConcreteMenuLabel menuLabel = MenuModelHelper.createMenuLabel(buffer);
        // Setup the menu title
        String title = "test menu";

        // Create a test menu
View Full Code Here


        String content = "test menu item";

        // Create the test DOM for the text buffer
        TestDOMOutputBuffer menuText = new TestDOMOutputBuffer();
        menuText.appendEncoded(content);

        // Create the test text, label, and then the menu item
        final ConcreteMenuText text = new ConcreteMenuText(elementDetails);
        text.setText(menuText);
        final ConcreteMenuLabel label = new ConcreteMenuLabel(
View Full Code Here

    protected void createMenuItem(MenuModelBuilder builder,
                                  String text,
                                  FormatReference pane) throws Exception{
        DOMOutputBuffer buffer = new TestDOMOutputBuffer();

        buffer.appendEncoded(text);

        builder.startMenuItem();

        builder.setHref(new LiteralLinkAssetReference("href"));
View Full Code Here

        // Add some content...
        Element element = buffer.openElement("a");
        element.setAttribute("href", testHref);
        element.setAttribute("accesskey", renderer.getShortcut().getText(TextEncoding.PLAIN));
        buffer.appendEncoded(testContent);
        buffer.closeElement(element);

        // End the call
        renderer.end(buffer);
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.