Class TopicServiceImpl
java.lang.Object
org.apache.unomi.services.impl.topics.TopicServiceImpl
- All Implemented Interfaces:
EventListener
,TopicService
,org.osgi.framework.BundleListener
,org.osgi.framework.SynchronousBundleListener
public class TopicServiceImpl
extends Object
implements TopicService, org.osgi.framework.SynchronousBundleListener
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
bundleChanged
(org.osgi.framework.BundleEvent bundleEvent) boolean
Removes the topic identified by the specified identifier.Retrieves the topic identified by the specified identifier.void
void
Saves the specified topic in the context server.Retrieves topic matching the specified query.void
setBundleContext
(org.osgi.framework.BundleContext bundleContext) void
setPersistenceService
(PersistenceService persistenceService)
-
Constructor Details
-
TopicServiceImpl
public TopicServiceImpl()
-
-
Method Details
-
setPersistenceService
-
setBundleContext
public void setBundleContext(org.osgi.framework.BundleContext bundleContext) -
load
Description copied from interface:TopicService
Retrieves the topic identified by the specified identifier.- Specified by:
load
in interfaceTopicService
- Parameters:
topicId
- the identifier of the topic to retrieve- Returns:
- the topic identified by the specified identifier or
null
if no such topic exists
-
save
Description copied from interface:TopicService
Saves the specified topic in the context server.- Specified by:
save
in interfaceTopicService
- Parameters:
topic
- the topic to be saved- Returns:
- the newly saved topic if the creation or update was successful,
null
otherwise
-
search
Description copied from interface:TopicService
Retrieves topic matching the specified query.- Specified by:
search
in interfaceTopicService
- Parameters:
query
- aQuery
specifying which elements to retrieve- Returns:
- a
PartialList
ofTopic
metadata
-
delete
Description copied from interface:TopicService
Removes the topic identified by the specified identifier.- Specified by:
delete
in interfaceTopicService
- Parameters:
topicId
- the identifier of the profile or persona to delete- Returns:
true
if the deletion was successful,false
otherwise
-
bundleChanged
public void bundleChanged(org.osgi.framework.BundleEvent bundleEvent) - Specified by:
bundleChanged
in interfaceorg.osgi.framework.BundleListener
-
postConstruct
public void postConstruct() -
preDestroy
public void preDestroy()
-