final void deactivateInternal(int reason, boolean disable, int trackingCount) { if (m_disposed) { return; } if (m_factoryInstance) { disposeInternal(reason); return; } log(LogService.LOG_DEBUG, "Deactivating component", null); // catch any problems from deleting the component to prevent the // component to remain in the deactivating state ! obtainActivationReadLock("deactivateInternal"); try { doDeactivate(reason, disable); } finally { releaseActivationReadLock("deactivateInternal"); } if (isFactory()) { clear(); } }
/** * Disposes off this component deactivating and disabling it first as required. After disposing * off the component, it may not be used anymore. * * <p>This method unlike the other state change methods immediately takes action and disposes the * component. The reason for this is, that this method has to actually complete before other * actions like bundle stopping may continue. */ final void disposeInternal(int reason) { log(LogService.LOG_DEBUG, "Disposing component (reason: " + reason + ")", null); doDeactivate(reason, true); clear(); }