Package org.springframework.context.support

Examples of org.springframework.context.support.FileSystemXmlApplicationContext


*
*/
public class HelloWorldClient {

  public static void main(String[] args) {
    ApplicationContext ctx = new FileSystemXmlApplicationContext(
        "./ch16/src/conf/http/helloWorld.xml");

        HelloWorld helloWorld = (HelloWorld)ctx.getBean("helloWorldService");
        System.out.println(helloWorld.getMessage());
  }
View Full Code Here


*
*/
public class MessageServiceClient {

  public static void main(String[] args) {
    ApplicationContext ctx = new FileSystemXmlApplicationContext(
        "./ch16/src/conf/http/messageService.xml");

        MessageService messageService = (MessageService)ctx.getBean("messageService");
        System.out.println(messageService.getMessage());
  }
View Full Code Here

public class HelloWorldClient {

    private HelloWorld helloWorldService;

    public static void main(String[] args) throws Exception {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
                "./ch16/src/conf/rmi/helloWorldClient.xml");

        HelloWorldClient helloWorldClient = (HelloWorldClient) ctx
                .getBean("helloWorldClient");
        helloWorldClient.run();

    }
View Full Code Here

*/
public class MessageServiceSecureClient {

    public static void main(String[] args) {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
                "./ch16/src/conf/http/messageServiceSecure.xml");

        MessageService messageService = (MessageService) ctx
                .getBean("messageService");
        System.out.println(messageService.getMessage());
    }
View Full Code Here

* @author robh
*/
public class HelloWorldClient {

    public static void main(String[] args) {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
        "./ch16/src/conf/jaxrpc/client.xml");

        HelloWorld helloWorld = (HelloWorld)ctx.getBean("helloWorldService");
        System.out.println(helloWorld.getMessage());
    }
View Full Code Here

* @author robh
*/
public class HelloWorldJndiClient {

    public static void main(String[] args) throws Exception {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
                "./ch16/src/conf/rmi/helloWorldJndiClient.xml");

        HelloWorld helloWorld = (HelloWorld) ctx.getBean("helloWorldService");
        System.out.println(helloWorld.getMessage());

    }
View Full Code Here

* @author robh
*/
public class SpringWithJobPersistence {

    public static void main(String[] args) throws Exception {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
                "./ch14/src/conf/quartzPersistent.xml");

        // get the scheduler
        Scheduler scheduler = (Scheduler) ctx.getBean("schedulerFactory");

        JobDetail job = scheduler.getJobDetail("otherJob",
                Scheduler.DEFAULT_GROUP);

        if (job == null) {
            // the job has not yet been created
            job = (JobDetail) ctx.getBean("job");
            job.setName("otherJob");
            job.getJobDataMap().put("message", "This is another message");

            Trigger trigger = new SimpleTrigger("simpleTrigger",
                    Scheduler.DEFAULT_GROUP, new Date(), null,
View Full Code Here

* @author robh
*/
public class SimpleSpringQuartzIntegrationExample {

    public static void main(String[] args) {
        ApplicationContext ctx = new FileSystemXmlApplicationContext(
        "./ch14/src/conf/quartzSimple.xml");
    }
View Full Code Here

        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

public class SpringCmdLineOptionStore implements CmdLineOptionStore {

   private ApplicationContext appContext;

   public SpringCmdLineOptionStore(String springConfig) {
      appContext = new FileSystemXmlApplicationContext(springConfig);
   }
View Full Code Here

TOP

Related Classes of org.springframework.context.support.FileSystemXmlApplicationContext

Copyright © 2018 www.massapicom. 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.