Examples of ApplicationListener


Examples of org.apache.tomcat.util.descriptor.web.ApplicationListener

    private void doTestWriter(Class<?> clazz, boolean useWriter) throws Exception {
        Tomcat tomcat = getTomcatInstance();
        // Must have a real docBase - just use temp
        Context ctx =
            tomcat.addContext("", System.getProperty("java.io.tmpdir"));
        ctx.addApplicationListener(new ApplicationListener(
                TesterEchoServer.Config.class.getName(), false));
        Tomcat.addServlet(ctx, "default", new DefaultServlet());
        ctx.addServletMapping("/", "default");

        WebSocketContainer wsContainer =
View Full Code Here

Examples of org.apache.tomcat.util.descriptor.web.ApplicationListener

            context.addFilterMap(filterMap);
        }
        context.setJspConfigDescriptor(webxml.getJspConfigDescriptor());
        for (String listener : webxml.getListeners()) {
            context.addApplicationListener(
                    new ApplicationListener(listener, false));
        }
        for (Entry<String, String> entry :
                webxml.getLocaleEncodingMappings().entrySet()) {
            context.addLocaleEncodingMappingParameter(entry.getKey(),
                    entry.getValue());
View Full Code Here

Examples of org.springframework.context.ApplicationListener

      final Dispatcher dispatcher = (Dispatcher) servletContext.getAttribute(Dispatcher.class.getName());
      if (dispatcher == null)
         throw new RuntimeException("RESTeasy Dispatcher is null, do ou have the ResteasyBootstrap listener configured?");

      ApplicationListener listener = new ApplicationListener()
      {
         public void onApplicationEvent(ApplicationEvent event)
         {
            if (event instanceof ContextRefreshedEvent)
            {
View Full Code Here

Examples of org.springframework.context.ApplicationListener

    }
   
    /** {@inheritDoc}*/
    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
        ctx = (AbstractApplicationContext)applicationContext;
        @SuppressWarnings("rawtypes")
        ApplicationListener listener = new ApplicationListener() {
            public void onApplicationEvent(ApplicationEvent event) {
                SpringBus.this.onApplicationEvent(event);
            }
        };
        ctx.addApplicationListener(listener);
View Full Code Here

Examples of railo.runtime.listener.ApplicationListener

  private static final long serialVersionUID = -3868545140988347285L;

  @Override
  public void doEnd(StorageScopeEngine engine,StorageScopeCleaner cleaner,String appName, String cfid) {
    CFMLFactoryImpl factory = engine.getFactory();
    ApplicationListener listener = factory.getConfig().getApplicationListener();
    try {
      cleaner.info("call onSessionEnd for "+appName+"/"+cfid);
      listener.onSessionEnd(factory, appName, cfid);
    }
    catch (Throwable t) {
      ExceptionHandler.log(factory.getConfig(),Caster.toPageException(t));
    }
  }
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.