Package org.apache.felix.dm.impl.index
Class ServiceRegistryCacheManager
java.lang.Object
org.apache.felix.dm.impl.index.ServiceRegistryCacheManager
This class manages the service registry cache creation.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ServiceRegistryCachegetCache()Gets the service registry cache, if enabled.static voidinit()Initialize the service registry cache.static voidregisterFilterIndex(FilterIndex index, org.osgi.framework.BundleContext context) Registers a FilterIndex into the service registry cache.static voidunregisterFilterIndex(FilterIndex index) Unregister a FilterIndex from the cache, and possibly close the cache in case it becomes empty.
-
Constructor Details
-
ServiceRegistryCacheManager
public ServiceRegistryCacheManager()
-
-
Method Details
-
getCache
Gets the service registry cache, if enabled.- Returns:
- the service registry cache, if enabled, or null
-
registerFilterIndex
Registers a FilterIndex into the service registry cache. The cache is created if necessary.- Parameters:
index- a new FilterIndex to be registered in the cachecontext- the bundle context used by the cache
-
unregisterFilterIndex
Unregister a FilterIndex from the cache, and possibly close the cache in case it becomes empty.- Parameters:
index- the FilterIndex to unregister
-
init
public static void init()Initialize the service registry cache.
-