public class BridgeTagService extends AbstractTagService
AbstractTagService.PAGE_PROVIDERS
TagService.Feature
Modifier and Type | Field and Description |
---|---|
protected AbstractTagService |
first |
protected AbstractTagService |
second |
ID
Constructor and Description |
---|
BridgeTagService(TagService first,
TagService second) |
Modifier and Type | Method and Description |
---|---|
boolean |
canUntag(CoreSession session,
String docId,
String label)
Returns whether or not the current session can untag tag on provided document.
|
void |
doCopyTags(CoreSession session,
String srcDocId,
String dstDocId,
boolean removeExistingTags) |
List<String> |
doGetTagDocumentIds(CoreSession session,
String label) |
Set<String> |
doGetTags(CoreSession session,
String docId) |
Set<String> |
doGetTagSuggestions(CoreSession session,
String label) |
void |
doTag(CoreSession session,
String docId,
String label,
String username) |
void |
doUntag(CoreSession session,
String docId,
String label) |
List<Tag> |
getTagCloud(CoreSession session,
String docId,
String username,
Boolean normalize)
Gets the tag cloud for a set of documents (tags with weight corresponding to their popularity).
|
boolean |
hasFeature(TagService.Feature feature)
Checks if a feature is available.
|
boolean |
supportsTag(CoreSession session,
String docId)
Checks if document support tag.
|
cleanLabel, cleanUsername, copyTags, copyTags, fireUpdateEvent, getDocumentTags, getDocumentTags, getItems, getSuggestions, getSuggestions, getTagDocumentIds, getTagDocumentIds, getTags, isEnabled, removeTags, replaceTags, tag, tag, untag, untag
protected final AbstractTagService first
protected final AbstractTagService second
public BridgeTagService(TagService first, TagService second)
public boolean hasFeature(TagService.Feature feature)
TagService
public boolean supportsTag(CoreSession session, String docId)
TagService
public List<Tag> getTagCloud(CoreSession session, String docId, String username, Boolean normalize)
TagService
If a docId is passed, only documents under it are considered, otherwise all documents in the database are used.
The cloud is returned unsorted.
session
- the sessiondocId
- the document id under which to look, or null
for all documentsusername
- the user name, or null
for all usersnormalize
- null for no weight normalization (a count is returned), FALSE
for 0-100 normalization,
TRUE
for logarithmic 0-100 normalizationpublic void doTag(CoreSession session, String docId, String label, String username)
doTag
in class AbstractTagService
public boolean canUntag(CoreSession session, String docId, String label)
TagService
canUntag
in interface TagService
canUntag
in class AbstractTagService
session
- the sessiondocId
- the document idlabel
- the tag, or null
for all tagspublic void doUntag(CoreSession session, String docId, String label)
doUntag
in class AbstractTagService
public Set<String> doGetTags(CoreSession session, String docId)
doGetTags
in class AbstractTagService
public void doCopyTags(CoreSession session, String srcDocId, String dstDocId, boolean removeExistingTags)
doCopyTags
in class AbstractTagService
public List<String> doGetTagDocumentIds(CoreSession session, String label)
doGetTagDocumentIds
in class AbstractTagService
public Set<String> doGetTagSuggestions(CoreSession session, String label)
doGetTagSuggestions
in class AbstractTagService
Copyright © 2018 Nuxeo. All rights reserved.