public void locationUpdated(InternalLocationProvider provider,
            LocationInformation location) {
        if (m_moduleState == POSITIONING_SUSPENDED) {
            if (LOG.isDebug()) {
                LOG.debug("LocationModule.locationUpdated()", "module in suspended state!");
            }
            return;
        }
        
        if (LOG.isDebug()) {
            LOG.debug("LocationModule.locationUpdated()", "to: "+location+" by "+provider+", crt provider is: "+m_currentProvider);
        }
        
        //the first provider to send a position will be set as current:
        if (m_currentProvider == null) {
            m_currentProvider = provider;
            updateAllLocationListeners(location, provider);
            if (m_currentProvider.getState() == LocationProvider.PROVIDER_STATE_AVAILABLE) {
                stopOtherProviders(m_currentProvider);
            }
        }
        else {
            if (m_currentProvider != provider) {
                // If another provider than the current one offers better 
                // positions at this time, set that as current provider
                // and update listeners with the position it sends.
                // For example, the current provider is GPS, but it's 
                // unavailable. A cell id provider has an updated position,
                // so it should be used because it's available.
                if (provider.isCurrentlyBetter(m_currentProvider)) {
                    if (LOG.isInfo()) {
                        LOG.info("LocationModule.locationUpdated()", 
                                "found better provider, set as crt: "+provider);
                    }
                    m_currentProvider = provider;
                    updateAllLocationListeners(location, provider);
                    if (m_currentProvider.getState() == LocationProvider.PROVIDER_STATE_AVAILABLE) {
                        stopOtherProviders(m_currentProvider);
                    }
                }
            }
            else {
                // just an update of the current provider
                updateAllLocationListeners(location, provider);
            }
        }
    }