org.apache.catalina.connector.Connector.getContainer()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(5.6k)|赞(0)|评价(0)|浏览(135)

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

Connector.getContainer介绍

[英]Return the Container used for processing requests received by this Connector.
[中]返回用于处理此连接器接收的请求的容器。

代码示例

代码示例来源:origin: org.glassfish.main.web/web-core

/**
 * Notify all container event listeners that a particular event has
 * occurred for this Adapter.  The default implementation performs
 * this notification synchronously using the calling thread.
 *
 * @param type Event type
 * @param data Event data
 */
public void fireAdapterEvent(String type, Object data) {
  if ( connector != null && connector.getContainer() != null) {
    try{
      ((ContainerBase)connector.getContainer())
        .fireContainerEvent(type,data);
    } catch (Throwable t){
      log.log(Level.SEVERE, LogFacade.REQUEST_PROCESSING_EXCEPTION, t);
    }
  }
}
// END SJSAS 6349248

代码示例来源:origin: tomcat/catalina

int n = -1;
for (int i = 0; i < connectors.length; i++) {
  if (connectors[i].getContainer() == (Container) engine) {
    n = i;
    break;

代码示例来源:origin: org.codehaus.fabric3.tomcat/fabric3-tomcat-extension

@Init()
public void init() {
  realm = connectorService.getConnector().getContainer().getRealm();
}

代码示例来源:origin: jboss.web/jbossweb

int n = -1;
for (int i = 0; i < connectors.length; i++) {
  if (connectors[i].getContainer() == (Container) engine) {
    n = i;
    break;

代码示例来源:origin: org.codehaus.fabric3.tomcat/fabric3-tomcat-extension

ClassLoader parentClassLoader = createParentClassLoader(parentClassLoaderId, uri);
StandardContext context = createContext(contextPath, resolved.getFile(), parentClassLoader, injectors);
for (Container container : connector.getContainer().findChildren()) {
  if (container instanceof StandardHost) {
    container.addChild(context);

代码示例来源:origin: org.codehaus.fabric3.tomcat/fabric3-tomcat-extension

public void deactivate(URI uri) throws WebApplicationActivationException {
  String contextPath = mappings.remove(uri);
  if (contextPath == null) {
    throw new WebApplicationActivationException("Context not registered for component: " + uri);
  }
  StandardContext context = null;
  try {
    for (Container container : connector.getContainer().findChildren()) {
      if (container instanceof StandardHost) {
        context = (StandardContext) container.findChild(contextPath);
        container.removeChild(context);
        try {
          context.destroy();
        } catch (Exception e) {
          throw new WebApplicationActivationException(e);
        }
        break;
      }
    }
    if (context == null) {
      throw new WebApplicationActivationException("Context not found for: " + contextPath);
    }
    context.stop();
    monitor.deactivated(contextPath);
  } catch (LifecycleException e) {
    throw new WebApplicationActivationException(e);
  }
}

代码示例来源:origin: org.codehaus.fabric3.tomcat/fabric3-tomcat-extension

@Init
public void init() throws ServletHostException {
  connector = connectorService.getConnector();
  dispatchingServlet = new Fabric3DispatchingServlet();
  Fabric3ServletWrapper wrapper = new Fabric3ServletWrapper(dispatchingServlet);
  wrapper.setName("Fabric3Servlet");
  for (Container container : connector.getContainer().findChildren()) {
    if (container instanceof StandardHost) {
      Container child = container.findChild("");
      if (child != null) {
        container.removeChild(child);
      }
      StandardContext context = createContext("", ".");
      context.addChild(wrapper);
      context.addServletMapping("/*", "Fabric3Servlet");
      container.addChild(context);
      try {
        dispatchingServlet.init(wrapper);
      } catch (ServletException e) {
        throw new AssertionError(e);
      }
    }
  }
}

代码示例来源:origin: org.glassfish.main.web/web-core

Container container = connector.getContainer();
enteringServletContainer(request, response);
try {

代码示例来源:origin: org.jboss.web/jbossweb

connector.getContainer().getPipeline().getFirst().invoke(request, response);

代码示例来源:origin: jboss.web/jbossweb

connector.getContainer().getPipeline().getFirst().invoke(request, response);

代码示例来源:origin: org.mobicents.arquillian.container/mss-tomcat-embedded-6

Connector[] connectors = service.findConnectors();
for (int i = 0; i < connectors.length; i++) {
  if (connectors[i].getContainer() == (Container) engine) {
    n = i;
    break;

代码示例来源:origin: tomcat/catalina

connector.getContainer().getPipeline().getFirst().invoke(request, response);

代码示例来源:origin: jboss.web/jbossweb

connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  request.getEvent().setType(HttpEvent.EventType.ERROR);
  error = true;
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());

代码示例来源:origin: org.osivia.portal.core/osivia-portal-jbossas-jbossweb-lib

/* 262 */         this.connector.getContainer().getPipeline().getFirst().invoke(request, response);

代码示例来源:origin: org.osivia.portal.core/osivia-portal-jbossas-jbossweb-lib

/* 174 */         this.connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
/* 182 */           this.connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
/* 192 */           this.connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());

代码示例来源:origin: org.jboss.web/jbossweb

connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  request.getEvent().setType(HttpEvent.EventType.ERROR);
  error = true;
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());
  connector.getContainer().getPipeline().getFirst().event(request, response, request.getEvent());

相关文章

Connector类方法