Example #1
0
 public static final void stopOsgiFwk() {
   try {
     EclipseStarter.shutdown();
   } catch (Exception e) {
     e.printStackTrace();
   }
 }
Example #2
0
  /**
   * Launches the osgi framework
   *
   * @return
   */
  public static final BundleContext launchOsgiFwk() {

    String[] equinoxArgs = {"-clean", "-console" /*, "1234", "-noExit" */};
    BundleContext context = null;
    try {
      context = EclipseStarter.startup(equinoxArgs, null);
    } catch (Exception e) {
      e.printStackTrace();
    }

    return context;
  }