Examples of BundleFactoryBean


Examples of org.springframework.osgi.bundle.BundleFactoryBean

    appContext.refresh();
  }

  public void testWithSymName() throws Exception {
    refresh();
    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&wSymName", BundleFactoryBean.class);
    assertSame(bundleA, fb.getObject());
    assertNull(fb.getLocation());
    assertNull(fb.getResource());

  }
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

  }

  public void testLocationAndResource() throws Exception {
    refresh();
    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&wLocation", BundleFactoryBean.class);
    assertEquals("fromServer", fb.getLocation());
    assertNull(fb.getSymbolicName());
    assertNotNull(fb.getResource());
  }
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    bundleToInstall[0] = startBundle;
    startBundle.start();

    refresh();

    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&start", BundleFactoryBean.class);

    BundleAction action = getAction(fb);
    assertSame(BundleAction.START, action);
    assertNull(getDestroyAction(fb));
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    // invoked on shutdown
    startBundle.stop();

    refresh();

    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&stop", BundleFactoryBean.class);
    assertSame(BundleAction.STOP, getDestroyAction(fb));

    assertSame(startBundle, appContext.getBean("stop"));

    appContext.close();
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    updateBundle.update();
    updateBundle.stop();
    refresh();

    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&update", BundleFactoryBean.class);

    BundleAction action = getAction(fb);
    assertSame(BundleAction.UPDATE, action);
    assertSame(BundleAction.STOP, getDestroyAction(fb));
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    installBundle.start();
    installBundle.uninstall();

    refresh();

    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&install", BundleFactoryBean.class);
    assertEquals("fromClient", fb.getLocation());
    assertEquals(1, INSTALL_BUNDLE_ACTION.size());
    assertEquals("fromClient", INSTALL_BUNDLE_ACTION.get(0));

    assertSame(installBundle, appContext.getBean("install"));
    appContext.close();
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    installBundle.update();
    installBundle.uninstall();

    refresh();

    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&updateFromActualLocation",
      BundleFactoryBean.class);
    assertEquals(1, INSTALL_BUNDLE_ACTION.size());

    assertSame(BundleAction.UPDATE, getAction(fb));
    assertSame(BundleAction.UNINSTALL, getDestroyAction(fb));
View Full Code Here

Examples of org.springframework.osgi.bundle.BundleFactoryBean

    ctrl.replay();
    appContext.getBeanFactory().registerSingleton("createdByTheTest", bnd);
    refresh();

    appContext.getBean("nested");
    BundleFactoryBean fb = (BundleFactoryBean) appContext.getBean("&nested", BundleFactoryBean.class);

    ctrl.verify();
  }
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.