public void detach() { if (bundle.getState() != Bundle.ACTIVE) { if (logger.isLoggable(Level.FINER)) { logger.logp(Level.FINER, "OSGiModuleImpl", "detach", "Ignoring stop of bundle {0} as it is in {1} state", new Object[]{bundle, toString(bundle.getState())} ); } return; } if (lifecyclePolicy!=null) { lifecyclePolicy.stop(this); lifecyclePolicy=null; } try { bundle.stop(); if (logger.isLoggable(Level.FINE)) { logger.logp(Level.FINE, "OSGiModuleImpl", "detach", "Stopped bundle = {0}", new Object[]{bundle}); } // bundle.uninstall(); } catch (BundleException e) { throw new RuntimeException(e); } }
public void detach() { if (bundle.getState() != Bundle.ACTIVE) { if (logger.isLoggable(Level.FINER)) { logger.logp(Level.FINER, "OSGiModuleImpl", "detach", "Ignoring stop of bundle {0} as it is in {1} state", new Object[]{bundle, toString(bundle.getState())} ); } return; } if (lifecyclePolicy!=null) { lifecyclePolicy.stop(this); lifecyclePolicy=null; } try { bundle.stop(); if (logger.isLoggable(Level.FINE)) { logger.logp(Level.FINE, "OSGiModuleImpl", "detach", "Stopped bundle = {0}", new Object[]{bundle}); } // bundle.uninstall(); } catch (BundleException e) { throw new RuntimeException(e); } }
lifecyclePolicy.stop(this); lifecyclePolicy=null;
lifecyclePolicy.stop(this); lifecyclePolicy=null;