Package org.apache.turbine.util.uri

Examples of org.apache.turbine.util.uri.DataURI


    public void init(Object data)
    {
        // we just blithely cast to RunData as if another object
        // or null is passed in we'll throw an appropriate runtime
        // exception.
        dataURI = new DataURI((RunData) data);

        Configuration conf =
                Turbine.getConfiguration().subset(CONTENT_TOOL_PREFIX);

        if (conf != null)
View Full Code Here


        clear();

        String enc = request.getCharacterEncoding();
        setCharacterEncoding(enc != null ? enc : "US-ASCII");

        cookiePath = new DataURI(data);

        Cookie[] cookies = request.getCookies();

        int cookiesCount = (cookies != null) ? cookies.length : 0;
View Full Code Here

        {
            sb.append("/").append(subDir);
        }
        sb.append("/").append(stripSlashes(resourceName));

        DataURI du = new DataURI(serverData);
        du.setScriptName(sb.toString());
        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

     *
     * @deprecated Use UITool.image(String imageId, RunData data) instead.
     */
    public String image(String imageId, RunData data)
    {
        DataURI du = new DataURI(data);

        StringBuffer sb = new StringBuffer();

        sb.append(resourcesDirectory).
                append('/').
                append(skinsDirectory).
                append('/').
                append(getSkin()).
                append('/').
                append(imagesDirectory).
                append('/').
                append(stripSlashes(imageId));

        du.setScriptName(sb.toString());

        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

     * @deprecated Use UITool.image(String imageId) instead.
     */
    public String image(String imageId)
    {
        ServerData sd = Turbine.getDefaultServerData();
        DataURI du = new DataURI(sd);

        StringBuffer sb = new StringBuffer();

        sb.append(resourcesDirectory).
                append('/').
                append(skinsDirectory).
                append('/').
                append(getSkin()).
                append('/').
                append(imagesDirectory).
                append('/').
                append(stripSlashes(imageId));

        du.setScriptName(sb.toString());
        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

     *
     * @deprecated Use UITool.getScript(String filename, RunData data) instead.
     */
    public String getScript(String filename, RunData data)
    {
        DataURI du = new DataURI(data);

        StringBuffer sb = new StringBuffer();

        sb.append(resourcesDirectory).
                append('/').
                append(skinsDirectory).
                append('/').
                append(getSkin()).
                append('/').
                append(stripSlashes(filename));

        du.setScriptName(sb.toString());
        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

     * @deprecated Use UITool.getScript(String filename) instead.
     */
    public String getScript(String filename)
    {
        ServerData sd = Turbine.getDefaultServerData();
        DataURI du = new DataURI(sd);

        StringBuffer sb = new StringBuffer();

        sb.append(resourcesDirectory).
                append('/').
                append(skinsDirectory).
                append('/').
                append(getSkin()).
                append('/').
                append(stripSlashes(filename));

        du.setScriptName(sb.toString());
        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

        clear();

        String enc = request.getCharacterEncoding();
        setCharacterEncoding(enc != null ? enc : "US-ASCII");

        cookiePath = new DataURI(new ServerData(request));

        Cookie[] cookies = request.getCookies();

        int cookiesCount = (cookies != null) ? cookies.length : 0;
View Full Code Here

    public void init(Object data)
    {
        // we just blithely cast to RunData as if another object
        // or null is passed in we'll throw an appropriate runtime
        // exception.
        dataURI = new DataURI((RunData) data);

        Configuration conf =
                Turbine.getConfiguration().subset(CONTENT_TOOL_PREFIX);

        if (conf != null)
View Full Code Here

        {
            sb.append("/").append(subDir);
        }
        sb.append("/").append(stripSlashes(resourceName));

        DataURI du = new DataURI(serverData);
        du.setScriptName(sb.toString());
        return wantRelative ? du.getRelativeLink() : du.getAbsoluteLink();
    }
View Full Code Here

TOP

Related Classes of org.apache.turbine.util.uri.DataURI

Copyright © 2018 www.massapicom. 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.