Package systems.dmx.facets
Class FacetsPlugin
- java.lang.Object
-
- systems.dmx.core.osgi.PluginActivator
-
- systems.dmx.facets.FacetsPlugin
-
- All Implemented Interfaces:
org.osgi.framework.BundleActivator,PluginContext,FacetsService
public class FacetsPlugin extends PluginActivator implements FacetsService
-
-
Field Summary
-
Fields inherited from class systems.dmx.core.osgi.PluginActivator
bundle, dmx, mf
-
-
Constructor Summary
Constructors Constructor Description FacetsPlugin()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddFacetTypeToTopic(long topicId, String facetTypeUri)RelatedTopicgetFacet(long topicId, String facetTypeUri)RelatedTopicgetFacet(DMXObject object, String facetTypeUri)Retrieves a facet value.List<RelatedTopic>getFacets(long topicId, String facetTypeUri)List<RelatedTopic>getFacets(DMXObject object, String facetTypeUri)Retrieves the values of a multi-facet.TopicgetFacettedTopic(long topicId, List<String> facetTypeUris)booleanhasFacet(long topicId, String facetTypeUri, long facetTopicId)voidupdateFacet(long topicId, String facetTypeUri, FacetValueModel value)voidupdateFacet(DMXObject object, String facetTypeUri, FacetValueModel value)Updates a facet.-
Methods inherited from class systems.dmx.core.osgi.PluginActivator
getBundleContext, getPluginName, getStaticResource, getUri, init, preInstall, publishFileSystem, serviceArrived, serviceGone, setCoreService, shutdown, start, stop, toString
-
-
-
-
Method Detail
-
getFacet
public RelatedTopic getFacet(long topicId, String facetTypeUri)
- Specified by:
getFacetin interfaceFacetsService
-
getFacet
public RelatedTopic getFacet(DMXObject object, String facetTypeUri)
Description copied from interface:FacetsServiceRetrieves a facet value. ### TODO: rename to getFacetValue?- Specified by:
getFacetin interfaceFacetsService- Parameters:
object- The facetted object: a topic, association, a type ...facetTypeUri- URI of the facet type.- Returns:
- The retrieved facet value (including its child topics) or
nullif no such topic extists.
-
getFacets
public List<RelatedTopic> getFacets(long topicId, String facetTypeUri)
- Specified by:
getFacetsin interfaceFacetsService
-
getFacets
public List<RelatedTopic> getFacets(DMXObject object, String facetTypeUri)
Description copied from interface:FacetsServiceRetrieves the values of a multi-facet. ### TODO: rename to getFacetValues?- Specified by:
getFacetsin interfaceFacetsService- Parameters:
object- The facetted object: a topic, association, a type ...facetTypeUri- URI of the facet type.- Returns:
- The retrieved facet values (including their child topics). The list may be empty.
-
getFacettedTopic
public Topic getFacettedTopic(long topicId, List<String> facetTypeUris)
- Specified by:
getFacettedTopicin interfaceFacetsService
-
addFacetTypeToTopic
public void addFacetTypeToTopic(long topicId, String facetTypeUri)- Specified by:
addFacetTypeToTopicin interfaceFacetsService
-
updateFacet
public void updateFacet(long topicId, String facetTypeUri, FacetValueModel value)- Specified by:
updateFacetin interfaceFacetsService
-
updateFacet
public void updateFacet(DMXObject object, String facetTypeUri, FacetValueModel value)
Description copied from interface:FacetsServiceUpdates a facet.- Specified by:
updateFacetin interfaceFacetsService- Parameters:
object- The facetted object: a topic, association, a type ...facetTypeUri- URI of the facet type.value- The new facet value.
-
hasFacet
public boolean hasFacet(long topicId, String facetTypeUri, long facetTopicId)- Specified by:
hasFacetin interfaceFacetsService
-
-