Examples of ILink


Examples of org.apache.tapestry.engine.ILink

        parameters.getParameterNames();
        control.setReturnValue(names);

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, false);

        assertSame(names, link.getParameterNames());

        verifyControls();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        parameters.getParameterValues("bedrock");
        control.setReturnValue(values);

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, false);

        assertSame(values, link.getParameterValues("bedrock"));

        verifyControls();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        parameters.getParameterNames();
        control.setReturnValue(new String[0]);

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, false);

        assertEquals(url.toString(), link.getURL());

        verifyControls();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        parameters.getParameterNames();
        control.setReturnValue(new String[0]);

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, false);

        assertEquals("this=foo&that=bar", link.getURL());

        verifyControls();
    }   
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        url.setParameter("bedrock", values);

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, false);

        assertEquals(url.toString(), link.getURL());

        verifyControls();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        QueryParameterMap parameters = newParameters();

        replayControls();

        ILink link = new PortletLink(cycle, url, parameters, true);

        assertEquals("/encoded-url#anchor", link.getURL("anchor", false));

        verifyControls();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        // Build a URL to select that component, as if by the captive
        // component itself (it's a Direct).

        DirectServiceParameter dsp = new DirectServiceParameter(this, serviceParameters);
        ILink link = service.getLink(getPage().getRequestCycle(), dsp);

        writer.begin("span");
        writer.attribute("class", "jwc-tag");

        writer.print("<");
        writer.print(token.getTag());

        writer.print(" jwcid=\"");

        writer.begin("span");
        writer.attribute("class", "jwc-id");

        writer.begin("a");
        writer.attribute("href", link.getURL());
        writer.print(id);

        writer.end(); // <a>
        writer.end(); // <span>
        writer.print('"');
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        _chartProvider = chartProvider;
    }

    public String buildURL(IRequestCycle cycle)
    {
        ILink l = _chartService.getLink(cycle, _chartProvider);

        return l.getURL();
    }
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

        boolean disabled = linkComponent.isDisabled();

        if (!disabled)
        {
            ILink l = linkComponent.getLink(cycle);

            if (hasBody)
                writer.begin(getElement());
            else
                writer.beginEmpty(getElement());
View Full Code Here

Examples of org.apache.tapestry.engine.ILink

            throw new ApplicationRuntimeException(message, component, null, null);
        }

        cycle.setAttribute(Tapestry.LINK_COMPONENT_ATTRIBUTE_NAME, component);

        ILink link = component.getLink(cycle);

        writer.begin("button");
        writer.attribute("type", "button");

        if (component.isDisabled())
        {
            writer.attribute("disabled", "disabled");
        }

        String url = link.getURL(component.getAnchor(), true);
        String target = component.getTarget();
        String onclick = (target == null) ? getScript(url) : getScript(url, target);

        writer.attribute("onclick", onclick);
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.