org.apache.tomcat.util.descriptor.web.WebXml.getServlets()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(4.9k)|赞(0)|评价(0)|浏览(191)

本文整理了Java中org.apache.tomcat.util.descriptor.web.WebXml.getServlets()方法的一些代码示例,展示了WebXml.getServlets()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WebXml.getServlets()方法的具体详情如下:
包路径:org.apache.tomcat.util.descriptor.web.WebXml
类名称:WebXml
方法名:getServlets

WebXml.getServlets介绍

暂无

代码示例

代码示例来源:origin: org.apache.tomcat/tomcat-catalina

private void convertJsps(WebXml webXml) {
  Map<String,String> jspInitParams;
  ServletDef jspServlet = webXml.getServlets().get("jsp");
  if (jspServlet == null) {
    jspInitParams = new HashMap<>();
    Wrapper w = (Wrapper) context.findChild("jsp");
    if (w != null) {
      String[] params = w.findInitParameters();
      for (String param : params) {
        jspInitParams.put(param, w.findInitParameter(param));
      }
    }
  } else {
    jspInitParams = jspServlet.getParameterMap();
  }
  for (ServletDef servletDef: webXml.getServlets().values()) {
    if (servletDef.getJspFile() != null) {
      convertJsp(servletDef, jspInitParams);
    }
  }
}

代码示例来源:origin: codefollower/Tomcat-Research

private void convertJsps(WebXml webXml) {
  Map<String,String> jspInitParams;
  ServletDef jspServlet = webXml.getServlets().get("jsp");
  if (jspServlet == null) {
    jspInitParams = new HashMap<>();
    Wrapper w = (Wrapper) context.findChild("jsp");
    if (w != null) {
      String[] params = w.findInitParameters();
      for (String param : params) {
        jspInitParams.put(param, w.findInitParameter(param));
      }
    }
  } else {
    jspInitParams = jspServlet.getParameterMap();
  }
  for (ServletDef servletDef: webXml.getServlets().values()) {
    if (servletDef.getJspFile() != null) {
      convertJsp(servletDef, jspInitParams);
    }
  }
}

代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core

private void convertJsps(WebXml webXml) {
  Map<String,String> jspInitParams;
  ServletDef jspServlet = webXml.getServlets().get("jsp");
  if (jspServlet == null) {
    jspInitParams = new HashMap<>();
    Wrapper w = (Wrapper) context.findChild("jsp");
    if (w != null) {
      String[] params = w.findInitParameters();
      for (String param : params) {
        jspInitParams.put(param, w.findInitParameter(param));
      }
    }
  } else {
    jspInitParams = jspServlet.getParameterMap();
  }
  for (ServletDef servletDef: webXml.getServlets().values()) {
    if (servletDef.getJspFile() != null) {
      convertJsp(servletDef, jspInitParams);
    }
  }
}

代码示例来源:origin: apache/ofbiz-framework

String servletMapping = null;
WebXml webXml = getWebXml(webAppInfo);
for (ServletDef servletDef : webXml.getServlets().values()) {
  if ("org.apache.ofbiz.webapp.control.ControlServlet".equals(servletDef.getServletClass()) || "org.apache.ofbiz.product.category.SeoControlServlet".equals(servletDef.getServletClass())) {
    String servletName = servletDef.getServletName();

代码示例来源:origin: org.apache.tomcat/tomcat-catalina

ServletDef servletDef = fragment.getServlets().get(servletName);

代码示例来源:origin: codefollower/Tomcat-Research

ServletDef servletDef = fragment.getServlets().get(servletName);

代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core

ServletDef servletDef = fragment.getServlets().get(servletName);

代码示例来源:origin: codefollower/Tomcat-Research

context.getNamingResources().addService(service);
for (ServletDef servlet : webxml.getServlets().values()) {
  Wrapper wrapper = context.createWrapper();

代码示例来源:origin: org.apache.tomcat/tomcat-catalina

context.getNamingResources().addService(service);
for (ServletDef servlet : webxml.getServlets().values()) {
  Wrapper wrapper = context.createWrapper();

代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core

context.getNamingResources().addService(service);
for (ServletDef servlet : webxml.getServlets().values()) {
  Wrapper wrapper = context.createWrapper();

代码示例来源:origin: codefollower/Tomcat-Research

fragment.getServlets().entrySet()) {
    if (servlets.containsKey(entry.getKey())) {
      mergeServlet(entry.getValue(),
          servlets.get(entry.getKey()), false);
    } else {
      if (temp.getServlets().containsKey(entry.getKey())) {
        if (!(mergeServlet(entry.getValue(),
            temp.getServlets().get(entry.getKey()), true))) {
          log.error(sm.getString(
              "webXml.mergeConflictServlet",
        temp.getServlets().put(entry.getKey(), entry.getValue());
servlets.putAll(temp.getServlets());

代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core

fragment.getServlets().entrySet()) {
    if (servlets.containsKey(entry.getKey())) {
      mergeServlet(entry.getValue(),
          servlets.get(entry.getKey()), false);
    } else {
      if (temp.getServlets().containsKey(entry.getKey())) {
        if (!(mergeServlet(entry.getValue(),
            temp.getServlets().get(entry.getKey()), true))) {
          log.error(sm.getString(
              "webXml.mergeConflictServlet",
        temp.getServlets().put(entry.getKey(), entry.getValue());
servlets.putAll(temp.getServlets());

代码示例来源:origin: org.apache.tomcat/tomcat-util-scan

fragment.getServlets().entrySet()) {
    if (servlets.containsKey(entry.getKey())) {
      mergeServlet(entry.getValue(),
          servlets.get(entry.getKey()), false);
    } else {
      if (temp.getServlets().containsKey(entry.getKey())) {
        if (!(mergeServlet(entry.getValue(),
            temp.getServlets().get(entry.getKey()), true))) {
          log.error(sm.getString(
              "webXml.mergeConflictServlet",
        temp.getServlets().put(entry.getKey(), entry.getValue());
servlets.putAll(temp.getServlets());

相关文章

WebXml类方法