Package org.apache.turbine.util

Examples of org.apache.turbine.util.ServerData


            else
            {
                log.info("ServerData Information retrieved from configuration.");
            }
            // Will be overwritten once the first request is run;
            serverData = new ServerData(serverName,
                    configuration.getInt(DEFAULT_SERVER_PORT_KEY,
                            URIConstants.HTTP_PORT),
                    configuration.getString(DEFAULT_SERVER_SCHEME_KEY,
                            URIConstants.HTTP),
                    configuration.getString(DEFAULT_SCRIPT_NAME_KEY),
View Full Code Here


                parms.putAll(this.getPortletConfig().getInitParameters());

                // Add web app root variable replacement
                try
                {
                    ServerData sd = new ServerData(TurbineServlet.getServerName(),
                                                Integer.parseInt(TurbineServlet.getServerPort()),
                                                TurbineServlet.getServerScheme(),
                                                TurbineServlet.getContextPath(),
                                                TurbineServlet.getContextPath());
                    DynamicURI uri = new DynamicURI(sd);               
View Full Code Here

                parms.putAll(this.getPortletConfig().getInitParameters());

                // Add web app root variable replacement
                try
                {
                    ServerData sd = new ServerData(TurbineServlet.getServerName(),
                                                Integer.parseInt(TurbineServlet.getServerPort()),
                                                TurbineServlet.getServerScheme(),
                                                TurbineServlet.getContextPath(),
                                                TurbineServlet.getContextPath());
                    DynamicURI uri = new DynamicURI(sd);               
View Full Code Here

            // Add all portlet parms
            parms.putAll(this.getPortletConfig().getInitParameters());
            // Add web app root variable replacement
            try
            {
                ServerData sd = new ServerData(TurbineServlet.getServerName(),
                                            Integer.parseInt(TurbineServlet.getServerPort()),
                                            TurbineServlet.getServerScheme(),
                                            TurbineServlet.getContextPath(),
                                            TurbineServlet.getContextPath());
                DynamicURI uri = new DynamicURI(sd);               
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).
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).
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

    /**
     * Performs any initialization that must happen before each test is run.
     */
    protected void setUp()
    {
        ServerData sd = new ServerData("www.testserver.com",
                URIConstants.HTTP_PORT, URIConstants.HTTP,
                "/servlet/turbine", "/context");
        turi = new TurbineURI(sd);
    }
View Full Code Here

    {
        if(serverData == null)
        {
            log.error("ServerData Information requested from Turbine before first request!");
            // Will be overwritten once the first request is run;
            serverData = new ServerData(null, URIConstants.HTTP_PORT,
                    URIConstants.HTTP, null, null);
        }
        return serverData;
    }
View Full Code Here

        catch (Exception x)
        {
            contextPath = "";
        }
        String scriptName = contextPath + req.getServletPath();
        data.setServerData(new ServerData(req.getServerName(),
                                          req.getServerPort(),
                                          req.getScheme(),
                                          scriptName,
                                          contextPath));
View Full Code Here

TOP

Related Classes of org.apache.turbine.util.ServerData

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.