Package org.springframework.context.support

Examples of org.springframework.context.support.GenericXmlApplicationContext.load()


   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:mybatis-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");       

    UserService userService = ctx.getBean("userService", UserService.class);
View Full Code Here


   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:jpa-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");
   
    CategoryService categoryService = ctx.getBean("categoryService", CategoryService.class);
View Full Code Here

   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:jpa-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");
   
    EntryAuditService entryAuditService = ctx.getBean("entryAuditService", EntryAuditService.class);
View Full Code Here

   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:jpa-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");
   
    CommentService commentService = ctx.getBean("commentService", CommentService.class);
View Full Code Here

   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:jpa-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");
   
    EntryService entryService = ctx.getBean("entryService", EntryService.class);
View Full Code Here

   * @param args
   */
  public static void main(String[] args) {

    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:mybatis-app-context.xml");
    ctx.refresh();
   
    System.out.println("App context initialized successfully");   
   
    EntryService entryService = ctx.getBean("entryService", EntryService.class);
View Full Code Here

    @Override
    public Promise<String> deploy(String springTemplate) {
        Resource templateResource = new ByteArrayResource(springTemplate.getBytes());
        GenericXmlApplicationContext appContext = new GenericXmlApplicationContext();
        appContext.setParent(applicationContext);
        appContext.load(templateResource);
        appContext.refresh();
        ApplicationStack applicationStack = appContext.getBean("applicationStack", ApplicationStack.class);
        applicationStack.deploy();
        return applicationStack.getUrl();
    }
View Full Code Here

public class ReproTests {

  @Test
  public void repro() throws Exception {
    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load(getClass(), "ReproTests-context.xml");
    ctx.refresh();

    C c = ctx.getBean(C.class);
    MyInterceptor interceptor = ctx.getBean(MyInterceptor.class);
View Full Code Here

public class ReproTests {

  @Test
  public void repro() {
    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:org/springframework/issues/ReproTests-context.xml");
    ctx.refresh();

    Foo foo = ctx.getBean(Foo.class);
    Bar bar = ctx.getBean(Bar.class);
View Full Code Here

public class ReproTests {

  @Test
  public void repro() {
    GenericXmlApplicationContext ctx = new GenericXmlApplicationContext();
    ctx.load("classpath:org/springframework/issues/ReproTests-context.xml");
    ctx.refresh();
  }

}
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.