Examples of addWelcomeFile()


Examples of org.apache.catalina.Context.addWelcomeFile()

    String contextPathURIBase = config.getContextPath();
    Context context =
        tomcat.addContext(contextPathURIBase == null ? "" : contextPathURIBase, contextPath.getAbsolutePath());
    context.addApplicationListener(new ApplicationListener(InitListener.class.getName(), false));
    context.setWebappVersion("3.0");
    context.addWelcomeFile("index.jspx");
    addErrorPages(context);

    ServletContext servletContext = context.getServletContext();
    servletContext.setAttribute(InitListener.INSTANCE_ID_KEY, config.getInstanceID());
    servletContext.setAttribute(InitListener.BUCKET_KEY, config.getBucket());
View Full Code Here

Examples of org.apache.catalina.Context.addWelcomeFile()

    context.addChild(jspServlet);
    context.addServletMapping("*.jsp", "jsp");
    context.addServletMapping("*.jspx", "jsp");

    // Set seme default welcome files
    context.addWelcomeFile("index.html");
    context.addWelcomeFile("index.htm");
    context.addWelcomeFile("index.jsp");
    context.setSessionTimeout(30);

    // Add some mime mappings
View Full Code Here

Examples of org.apache.catalina.Context.addWelcomeFile()

    context.addServletMapping("*.jsp", "jsp");
    context.addServletMapping("*.jspx", "jsp");

    // Set seme default welcome files
    context.addWelcomeFile("index.html");
    context.addWelcomeFile("index.htm");
    context.addWelcomeFile("index.jsp");
    context.setSessionTimeout(30);

    // Add some mime mappings
    context.addMimeMapping("html", "text/html");
View Full Code Here

Examples of org.apache.catalina.Context.addWelcomeFile()

    context.addServletMapping("*.jspx", "jsp");

    // Set seme default welcome files
    context.addWelcomeFile("index.html");
    context.addWelcomeFile("index.htm");
    context.addWelcomeFile("index.jsp");
    context.setSessionTimeout(30);

    // Add some mime mappings
    context.addMimeMapping("html", "text/html");
    context.addMimeMapping("htm", "text/html");
View Full Code Here

Examples of org.apache.catalina.Context.addWelcomeFile()

    context.addLifecycleListener(new DefaultWebXmlListener());
    context.setSessionTimeout(30);
    for (int i = 0; i < DEFAULT_MIME_MAPPINGS.length;) {
      context.addMimeMapping(DEFAULT_MIME_MAPPINGS[i++], DEFAULT_MIME_MAPPINGS[i++]);
    }
    context.addWelcomeFile("index.jsp");

    File configFile = new File("src/main/webapp/META-INF/context.xml");
    context.setConfigFile(configFile.toURI().toURL());

    ContextConfig ctxCfg = new ContextConfig();
View Full Code Here

Examples of org.apache.catalina.Context.addWelcomeFile()

    context.addLifecycleListener(new DefaultWebXmlListener());
    context.setSessionTimeout(30);
    for (int i = 0; i < DEFAULT_MIME_MAPPINGS.length;) {
      context.addMimeMapping(DEFAULT_MIME_MAPPINGS[i++], DEFAULT_MIME_MAPPINGS[i++]);
    }
    context.addWelcomeFile("index.jsp");

    File configFile = new File("src/main/webapp/META-INF/context.xml");
    context.setConfigFile(configFile.toURI().toURL());

    ContextConfig ctxCfg = new ContextConfig();
View Full Code Here

Examples of org.apache.catalina.core.StandardContext.addWelcomeFile()

        File appDir = new File("test/webapp");

        StandardContext ctxt = (StandardContext) tomcat.addWebapp(null, "/test",
                appDir.getAbsolutePath());
        ctxt.setReplaceWelcomeFiles(true);
        ctxt.addWelcomeFile("index.jsp");
        // Mapping for *.do is defined in web.xml
        ctxt.addWelcomeFile("index.do");

        tomcat.start();
        ByteChunk bc = new ByteChunk();
View Full Code Here

Examples of org.apache.catalina.core.StandardContext.addWelcomeFile()

        StandardContext ctxt = (StandardContext) tomcat.addWebapp(null, "/test",
                appDir.getAbsolutePath());
        ctxt.setReplaceWelcomeFiles(true);
        ctxt.addWelcomeFile("index.jsp");
        // Mapping for *.do is defined in web.xml
        ctxt.addWelcomeFile("index.do");

        tomcat.start();
        ByteChunk bc = new ByteChunk();
        int rc = getUrl("http://localhost:" + getPort() +
                "/test/welcome-files", bc, new HashMap<String,List<String>>());
View Full Code Here

Examples of org.apache.catalina.core.StandardContext.addWelcomeFile()

        File appDir = new File("test/webapp");

        StandardContext ctxt = (StandardContext) tomcat.addWebapp(null, "/test",
                appDir.getAbsolutePath());
        ctxt.setReplaceWelcomeFiles(true);
        ctxt.addWelcomeFile("index.jsp");
        // Mapping for *.do is defined in web.xml
        ctxt.addWelcomeFile("index.do");

        // Simulate STRICT_SERVLET_COMPLIANCE
        ctxt.setResourceOnlyServlets("");
View Full Code Here

Examples of org.apache.catalina.core.StandardContext.addWelcomeFile()

        StandardContext ctxt = (StandardContext) tomcat.addWebapp(null, "/test",
                appDir.getAbsolutePath());
        ctxt.setReplaceWelcomeFiles(true);
        ctxt.addWelcomeFile("index.jsp");
        // Mapping for *.do is defined in web.xml
        ctxt.addWelcomeFile("index.do");

        // Simulate STRICT_SERVLET_COMPLIANCE
        ctxt.setResourceOnlyServlets("");

        tomcat.start();
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.