Package org.springframework.web.context

Examples of org.springframework.web.context.ConfigurableWebApplicationContext.refresh()


        URL customConfig = arg0.getServletContext().getResource(yfacesCtx);
        configs = new String[] { configs[0], customConfig.toExternalForm() };
      }
      log.debug("Using spring configuration:" + Arrays.asList(configs));
      ctx.setConfigLocations(configs);
      ctx.refresh();
      new YApplicationContext(ctx);

    } catch (MalformedURLException e) {
      e.printStackTrace();
    }
View Full Code Here


    wac.setParent(parent);
    wac.setServletContext(filter.getFilterConfig().getServletContext());
    wac.setConfigLocation(getContextConfigLocation(filter));

    postProcessWebApplicationContext(wac, filter);
    wac.refresh();

    return wac;
  }

  /**
 
View Full Code Here

        ConfigurableWebApplicationContext ac = new XmlWebApplicationContext();
        ServletContext msc = (ServletContext) new MockServletContext();
        msc.setAttribute(WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE, ac);
        ac.setServletContext(msc);
        ac.setConfigLocations(new String[] {"org/apache/struts2/spring/StrutsSpringObjectFactoryTest-applicationContext.xml"});
        ac.refresh();
        StrutsSpringObjectFactory fac = new StrutsSpringObjectFactory("constructor", null, null, msc);

        assertEquals(AutowireCapableBeanFactory.AUTOWIRE_CONSTRUCTOR, fac.getAutowireStrategy());
    }
View Full Code Here

    wac.setParent(parent);
    wac.setServletContext(filter.getFilterConfig().getServletContext());
    wac.setConfigLocation(getContextConfigLocation(filter));

    postProcessWebApplicationContext(wac, filter);
    wac.refresh();

    return wac;
  }

  /**
 
View Full Code Here

    wac.setParent(parent);
    wac.setServletContext(filter.getFilterConfig().getServletContext());
    wac.setConfigLocation(getContextConfigLocation(filter));

    postProcessWebApplicationContext(wac, filter);
    wac.refresh();

    return wac;
  }

  /**
 
View Full Code Here

    wac.setNamespace( getServletName() );
    String springFile =
        PentahoSystem.getApplicationContext()
            .getSolutionPath( "system" + File.separator + "pentahoServices.spring.xml" ); //$NON-NLS-1$ //$NON-NLS-2$
    wac.setConfigLocations( new String[] { springFile } );
    wac.refresh();

    return wac;
  }

}
View Full Code Here

    wac.setNamespace( getServletName() );
    String springFile =
        PentahoSystem.getApplicationContext()
            .getSolutionPath( "system" + File.separator + "pentahoServices.spring.xml" ); //$NON-NLS-1$ //$NON-NLS-2$
    wac.setConfigLocations( new String[] { springFile } );
    wac.refresh();

    return wac;
  }

  protected void doPost( HttpServletRequest request, HttpServletResponse response ) throws ServletException {
View Full Code Here

    wac.setNamespace( getServletName() );
    String springFile =
        PentahoSystem.getApplicationContext()
            .getSolutionPath( "system" + File.separator + "pentahoServices.spring.xml" ); //$NON-NLS-1$ //$NON-NLS-2$
    wac.setConfigLocations( new String[] { springFile } );
    wac.refresh();

    return wac;
  }

}
View Full Code Here

      ctx = servletContext;
    }
    ContextLoader loader = new ContextLoader();
    ConfigurableWebApplicationContext appCtx = (ConfigurableWebApplicationContext) loader.initWebApplicationContext(ctx);
    appCtx.setParent(applicationContext);
    appCtx.refresh();

    ctx.setAttribute(WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE, appCtx);

    ConfigurableBeanFactory appFactory = appCtx.getBeanFactory();
View Full Code Here

    wac.setParent(parent);
    wac.setServletContext(filter.getFilterConfig().getServletContext());
    wac.setConfigLocation(getContextConfigLocation(filter));

    postProcessWebApplicationContext(wac, filter);
    wac.refresh();

    return wac;
  }

  /**
 
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.