Examples of FileSystemXmlApplicationContext


Examples of org.springframework.context.support.FileSystemXmlApplicationContext

        // file based
        if (getFileApplicationContextUri() != null) {
            String[] args = getFileApplicationContextUri().split(";");

            if (parentContext != null) {
                return new FileSystemXmlApplicationContext(args, parentContext);
            } else {
                return new FileSystemXmlApplicationContext(args);
            }
        }

        // default to classpath based
        String[] args = getApplicationContextUri().split(";");
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

        if (getFileApplicationContextUri() != null) {
            String[] args = getFileApplicationContextUri().split(";");

            ApplicationContext parentContext = getParentApplicationContext();
            if (parentContext != null) {
                return new FileSystemXmlApplicationContext(args, parentContext);
            } else {
                return new FileSystemXmlApplicationContext(args);
            }
        }
       
        // default to classpath based
        String[] args = getApplicationContextUri().split(";");
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

        if (getFileApplicationContextUri() != null) {
            String[] args = getFileApplicationContextUri().split(";");

            ApplicationContext parentContext = getParentApplicationContext();
            if (parentContext != null) {
                return new FileSystemXmlApplicationContext(args, parentContext);
            } else {
                return new FileSystemXmlApplicationContext(args);
            }
        }

        // default to classpath based
        String[] args = getApplicationContextUri().split(";");
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

    }

    @Override
    protected void setUp() throws Exception {
        super.setUp();
        applicationContext = new FileSystemXmlApplicationContext("src/main/webapp/WEB-INF/applicationContext.xml");
        applicationContext.start();
        camelContext = (CamelContext) applicationContext.getBean("camelContext", CamelContext.class);
        assertNotNull("camelContext", camelContext);
    }
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

            if (!"".equals(nrOfCallsString)) {
                nrOfCalls = Integer.parseInt(nrOfCallsString);
            }

            ListableBeanFactory beanFactory = new FileSystemXmlApplicationContext("clientContext.xml");
            ClientApplication client = new ClientApplication(beanFactory);

            client.invokeContactManager(new UsernamePasswordAuthenticationToken(username, password), nrOfCalls);
            System.exit(0);
        }
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

 
  public boolean start() {
    if (ctx != null)
      IocInterceptor.ctx = ctx;
    else if (configurations != null)
      IocInterceptor.ctx = new FileSystemXmlApplicationContext(configurations);
    else
      IocInterceptor.ctx = new FileSystemXmlApplicationContext(PathKit.getWebRootPath() + "/WEB-INF/applicationContext.xml");
    return true;
  }
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

        if (getFileApplicationContextUri() != null) {
            String[] args = getFileApplicationContextUri().split(";");

            ApplicationContext parentContext = getParentApplicationContext();
            if (parentContext != null) {
                return new FileSystemXmlApplicationContext(args, parentContext);
            } else {
                return new FileSystemXmlApplicationContext(args);
            }
        }

        // default to classpath based
        String[] args = getApplicationContextUri().split(";");
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

public class TestBatchingAuditTrail {
 
 

  public static void main(String[] args) throws Exception {
    final ApplicationContext ctx = new FileSystemXmlApplicationContext("src/test/resources/persistent-engine-application-context.xml");
    AuditTrail auditTrail = ctx.getBean(AuditTrail.class);
    for (int i=0; i<100; i++) {
      auditTrail.asynchLog(2, new Date(), "conv12345678901234567890123456789012", "ctx", "proc12345678901234567890123456789012", "corr12345678901234567890123456789012", null, "TEXT", "testMessage");
    }
    Thread.sleep(2000);
   
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

    if (args.length == 0) {
      System.out.println("Usage: "+SpringEngineStarter.class.getName()+" <configLocations>");
      System.exit(-2);
    }
    try {
      new FileSystemXmlApplicationContext(args);
    }
    catch(Exception e) {
      logger.error("Startup failed",e);
      System.exit(-1);
    }
View Full Code Here

Examples of org.springframework.context.support.FileSystemXmlApplicationContext

     * NOTE: This only works against the SENS modules! Not vanilla geoserver!
     *
     * @param args
     */
    public static void main(String[] args) {
        ApplicationContext context = new FileSystemXmlApplicationContext(
                "src/test/java/spring.xml");
        IPreferenceStore controller = (IPreferenceStore) context.getBean(
                "preferenceService");
        System.out.println("Before setDefault: " + controller.getString("test"));
        controller.setDefault("test", "defaultValue");
        System.out.println("After setDefault: " + controller.getString("test"));
        controller.set("test", "setValue");
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.