public class DefaultLabelManager extends Object implements LabelManagerInternal
CONTENT_TYPES, DEFAULT_LABEL_COUNT, FAVOURITE_LABEL, FAVOURITE_LABEL_YANKEE, LABEL_ADDED, LABEL_CREATED, LABEL_DELETED, LABEL_REMOVED, NO_CHANGE, NO_MAX_RESULTS, NO_OFFSET| Constructor and Description |
|---|
DefaultLabelManager() |
| Modifier and Type | Method and Description |
|---|---|
int |
addLabel(Labelable labelable,
Label label)
Add a label to the specified content.
|
Set<RankedLiteLabelSearchResult> |
calculateRanksForLiteLabels(List<LiteLabelSearchResult> labelList,
Comparator<? super RankedLiteLabelSearchResult> comparator)
Calculate ranks for input labels.
|
Label |
createLabel(Label label) |
boolean |
deleteLabel(Label label)
Delete the specified label.
|
boolean |
deleteLabel(long id)
Delete the label with the specified id.
|
PageResponse<Label> |
findGlobalLabelsByNamePrefix(String namePrefix,
LimitedRequest pageRequest)
Returns global-namespaced labels starting with the given string.
|
PageResponse<Label> |
findTeamLabelsByNamePrefix(String namePrefix,
LimitedRequest pageRequest)
Returns team-namespaced labels starting with the given string.
|
PartialList<ContentEntityObject> |
getAllContentForAllLabels(int offset,
int maxResults,
Label... labels)
Retrieve all ContentEntityObjects, current or deleted which are labelled with ALL provided labels.
|
PartialList<ContentEntityObject> |
getAllContentForLabel(int offset,
int maxResults,
Label label)
Retrieve all ContentEntityObjects, current or deleted which are labelled with the provided label.
|
List |
getContent(Label label)
Get all content associated with a label
Get all versions of content associated with a label and any space.
|
int |
getContentCount(Label label) |
List<? extends Labelable> |
getContentForAllLabels(Collection<Label> labels,
int maxResults,
int offset) |
PartialList<ContentEntityObject> |
getContentForAllLabels(int offset,
int maxResults,
Label... labels)
Retrieve current ContentEntityObjects which are labelled with ALL provided labels.
|
PartialList<ContentEntityObject> |
getContentForLabel(int offset,
int maxResults,
Label label)
Retrieve current ContentEntityObjects which are labelled with the provided label.
|
PartialList<ContentEntityObject> |
getContentInSpaceForAllLabels(int offset,
int maxResults,
String spaceKey,
Label... labels)
Retrieve current ContentEntityObjects in the given space which are labelled with ALL provided labels.
|
PartialList<ContentEntityObject> |
getContentInSpaceForLabel(int offset,
int maxResults,
String spaceKey,
Label label)
Retrieve current ContentEntityObjects in the given space which are labelled with the provided label.
|
PartialList<ContentEntityObject> |
getContentInSpacesForAllLabels(int offset,
int maxResults,
Set<String> spaceKeys,
Label... labels)
Retrieve current ContentEntityObjects in the given spaces which are labelled with ALL provided labels.
|
List<? extends Labelable> |
getCurrentContentForLabel(Label label)
Get all content associated with a label and space
Get all current content associated with a label and any space.
|
List<? extends Labelable> |
getCurrentContentForLabelAndSpace(Label label,
String spaceKey)
Get all current content associated with a label and space.
|
List<? extends Labelable> |
getCurrentContentWithPersonalLabel(String username)
Get all current content labelled by a user
|
List<Labelling> |
getFavouriteLabellingsByContentIds(Collection<ContentId> contentIds,
com.atlassian.sal.api.user.UserKey userKey)
Get the labellings that represent the favourite labellings for the given user on the given content.
|
List<Space> |
getFavouriteSpaces(String username) |
<T extends EditableLabelable> |
getForLabel(Class<T> labelableClass,
int offset,
int maxResults,
Label label)
Retrieve EditableLabelables of the supplied type which are labelled with the provided label.
|
<T extends EditableLabelable> |
getForLabels(Class<T> labelableClass,
int offset,
int maxResults,
Label... labels)
Retrieve EditableLabelables of the supplied type which are labelled with the provided labels.
|
PartialList<EditableLabelable> |
getForLabels(int offset,
int maxResults,
Label... labels)
Retrieve EditableLabelables of any type which are labelled with the provided labels.
|
Label |
getLabel(Label label)
Retrieve the persistent instance of the label with the exact same details as the specified label.
|
Label |
getLabel(long id)
Retrieve a label based on its id.
|
Label |
getLabel(ParsedLabelName parsedLabelName)
Retrieve the label by name.
|
Label |
getLabel(String unparsedLabelName)
convenience method to fetch a label without having to call the label parser
|
Label |
getLabel(String labelName,
Namespace namespace)
Convenience method to fetch a label without having to create a Label object
|
List<Label> |
getLabels(Collection<String> unparsedLabelNames)
convenience method to fetch labels without having to call the label parser
|
List<Label> |
getLabelsByDetail(String labelName,
String namespace,
String spaceKey,
String owner)
Retrieves the labels matching the given labelName, namespace or owner
|
List<Label> |
getLabelsInSpace(String key)
Retrieve all of the labels that label content within the specified space.
|
List<Label> |
getLabelsInSpace(String key,
LimitedRequest limitedRequest)
Get all label in Space with pagination
|
List<LabelSearchResult> |
getMostPopularLabels()
Retrieve the list of the DEFAULT_LABEL_COUNT most popular labels within the system.
|
List<LabelSearchResult> |
getMostPopularLabels(int count)
Retrieve the most popular labels within the system.
|
List<LiteLabelSearchResult> |
getMostPopularLabelsInSiteLite(int maxResults)
Returns most used labels across the site.
|
List<LabelSearchResult> |
getMostPopularLabelsInSpace(String key)
Retrieve the list of the DEFAULT_LABEL_COUNT most used labels in the specific space, ordered from most
popular to least popular.
|
List<LabelSearchResult> |
getMostPopularLabelsInSpace(String key,
int count)
Retrieve a list of the 'n' most used labels in the specified space, ordered from most popular to least
popular.
|
List<LiteLabelSearchResult> |
getMostPopularLabelsInSpaceLite(String spaceKey,
int maxResults)
Returns most used labels.
|
Set<RankedLabelSearchResult> |
getMostPopularLabelsWithRanks(Comparator<? super RankedLabelSearchResult> comparator)
Retrieve a set of the DEFAULT_LABEL_COUNT most popular labels within the system, including their ranks and
ordered using the compartor provided.
|
Set<RankedLabelSearchResult> |
getMostPopularLabelsWithRanks(int maxResults,
Comparator<? super RankedLabelSearchResult> comparator)
Retrieve the most popular labels within the system, including their ranks and ordered using the comparator
provided.
|
Set<RankedLabelSearchResult> |
getMostPopularLabelsWithRanksInSpace(String key,
int maxResults,
Comparator<? super RankedLabelSearchResult> comparator)
Retrieve a set of the 'n' most used labels in the specified space, ordered using the compartor given.
|
List<Labelling> |
getRecentlyUsedLabellings(int maxResults) |
List<Labelling> |
getRecentlyUsedLabellingsInSpace(String spaceKey,
int maxResults) |
List<Label> |
getRecentlyUsedLabels()
Retrieve the DEFAULT_LABEL_COUNT most recently used labels within the system.
|
List<Label> |
getRecentlyUsedLabels(int maxResults)
Retrieve the x most recently used labels.
|
List<Label> |
getRecentlyUsedLabelsInSpace(String key)
Retrieve the DEFAULT_LABEL_COUNT most recently used labels within the specified space.
|
List<Label> |
getRecentlyUsedLabelsInSpace(String key,
int maxResults)
Retrieve the most recently used labels within the specified spae.
|
List<Labelling> |
getRecentlyUsedPersonalLabellings(String username,
int maxResults) |
List<Label> |
getRecentlyUsedPersonalLabels(String username)
Retrieve the labels that were recently used by currently authenticated user.
|
List<Label> |
getRecentlyUsedPersonalLabels(String username,
int maxResults)
Retrieve the labels that were recently used by currently authenticated user.
|
List<Label> |
getRelatedLabels(Label label)
Retrieve the DEFAULT_LABEL_COUNT labels that are 'related' to the specified label.
|
List<Label> |
getRelatedLabels(Label label,
int count)
Retrieve the labels that are 'related' to the specified label.
|
List<Label> |
getRelatedLabels(List<? extends Label> labels,
String spaceKey,
int maxResultsPerLabel)
Retrieve the labels that are 'related' to the labels in the list.
|
List<Label> |
getRelatedLabelsInSpace(Label label,
String spaceKey)
Retrieve the DEFAULT_LABEL_COUNT labels that are 'related' to the specified label and that are used to label
content within the specified space.
|
List<Label> |
getRelatedLabelsInSpace(Label label,
String spaceKey,
int maxResults)
Retrieve the labels that are 'related' to the specified label and that are used to to label content within
the specified space.
|
List<Space> |
getSpacesContainingContentWithLabel(Label label)
Look up the spaces that have been labelled by the specific label.
|
List<Space> |
getSpacesWithLabel(Label label)
Spaces cannot be directly labelled.
|
List<Label> |
getSuggestedLabels(Labelable content)
Retrieve the DEFAULT_LABEL_COUNT suggested labels for the specified content.
|
List<Label> |
getSuggestedLabels(Labelable content,
int count)
Retrieve the suggested labels for the specified content.
|
List<Label> |
getSuggestedLabelsInSpace(Labelable content,
String spaceKey)
Retrieve the DEFAULT_LABEL_COUNT suggested labels for the specified content bound to the specified space.
|
List<Label> |
getSuggestedLabelsInSpace(Labelable content,
String spaceKey,
int maxResults)
Retrieve the suggested labels for the specified content bound to the specified space.
|
List<Label> |
getTeamLabels()
Retrieve all of the team labels in the system.
|
List<Label> |
getTeamLabels(String name)
Retrieve all of the team labels in the system with name.
|
List<Label> |
getTeamLabelsForSpace(String spaceKey)
Retrieve all of the team labels used to label content in the specified space.
|
List<Label> |
getTeamLabelsForSpaces(Collection<Space> spaces)
Retrieve all of the team labels used to label content in the specified spaces.
|
long |
getTotalLabelInSpace(String key)
Get total label in a particular space
|
List<Label> |
getUsersLabels(String name)
Retrieve the personal labels that belong to the specified user.
|
void |
removeAllLabels(Labelable content)
Remove all of the labels from the specified content.
|
int |
removeLabel(Labelable content,
Label label)
Remove a label from the specified content.
|
void |
removeLabels(Labelable content,
List labels)
removes a list of labels from the labelable object
|
void |
setEventManager(com.atlassian.event.EventManager manager)
Deprecated.
since 7.5 use
setEventPublisher(EventPublisher) |
void |
setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher) |
void |
setIndexer(ConfluenceIndexer indexer)
Deprecated.
since 7.5 indexing performed via events
|
void |
setLabelDao(LabelDao dao) |
void |
setLabelDaoInternal(LabelDaoInternal dao) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitfindGlobalLabelsByNamePrefix, findTeamLabelsByNamePrefixpublic void setLabelDao(@Qualifier(value="labelDao")
LabelDao dao)
public void setLabelDaoInternal(@Qualifier(value="labelDao")
LabelDaoInternal dao)
@Deprecated public void setEventManager(com.atlassian.event.EventManager manager)
setEventPublisher(EventPublisher)public void setEventPublisher(com.atlassian.event.api.EventPublisher eventPublisher)
@Deprecated public void setIndexer(ConfluenceIndexer indexer)
public int addLabel(Labelable labelable, Label label)
LabelManager
Note: the specified label does not need to be persistent. A persistent instance of the label will be created
if necessary.
eg: you can write code like: labelManager.addLabel(page, new Label("name", "namespace", "owner"));
addLabel in interface LabelManagerpublic int removeLabel(Labelable content, Label label)
LabelManagerremoveLabel in interface LabelManagerpublic void removeLabels(Labelable content, List labels)
LabelManagerremoveLabels in interface LabelManagerpublic void removeAllLabels(Labelable content)
LabelManagerremoveAllLabels in interface LabelManagerpublic Label getLabel(long id)
getLabel in interface LabelManagerpublic List<Label> getSuggestedLabels(Labelable content)
LabelManagergetSuggestedLabels in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getSuggestedLabels(Labelable content, int count)
LabelManagergetSuggestedLabels in interface LabelManagercount - is the maximum number of labels to be returned.public List<Label> getSuggestedLabelsInSpace(Labelable content, String spaceKey)
LabelManagergetSuggestedLabelsInSpace in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getSuggestedLabelsInSpace(Labelable content, String spaceKey, int maxResults)
LabelManagergetSuggestedLabelsInSpace in interface LabelManagermaxResults - is the maximum number of labels to be returned.public List<Label> getRelatedLabels(Label label)
LabelManagergetRelatedLabels in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getRelatedLabels(Label label, int count)
LabelManagergetRelatedLabels in interface LabelManagercount - is the maximum number of labels to be returned.public List<Label> getRelatedLabels(List<? extends Label> labels, String spaceKey, int maxResultsPerLabel)
LabelManagergetRelatedLabels in interface LabelManagerspaceKey - - may be null to search globallymaxResultsPerLabel - is the maximum number of labels to be returned for each label.public List<Label> getRelatedLabelsInSpace(Label label, String spaceKey)
LabelManagergetRelatedLabelsInSpace in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getRelatedLabelsInSpace(Label label, String spaceKey, int maxResults)
LabelManagergetRelatedLabelsInSpace in interface LabelManagerpublic List<Space> getSpacesContainingContentWithLabel(Label label)
LabelManagergetSpacesContainingContentWithLabel in interface LabelManagerpublic List<Label> getUsersLabels(String name)
LabelManagergetUsersLabels in interface LabelManagerpublic List<Label> getTeamLabels()
LabelManagergetTeamLabels in interface LabelManagerpublic List<Label> getTeamLabels(String name)
LabelManagergetTeamLabels in interface LabelManagerpublic List<Label> getTeamLabelsForSpace(String spaceKey)
LabelManagergetTeamLabelsForSpace in interface LabelManagerpublic List<Label> getTeamLabelsForSpaces(Collection<Space> spaces)
LabelManagergetTeamLabelsForSpaces in interface LabelManagerspaces - collection of spaces whose labels to getpublic List<Label> getRecentlyUsedLabelsInSpace(String key)
LabelManagergetRecentlyUsedLabelsInSpace in interface LabelManagerkey - identifies the space to which the results are restricted.LabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getRecentlyUsedLabelsInSpace(String key, int maxResults)
LabelManagergetRecentlyUsedLabelsInSpace in interface LabelManagermaxResults - is the maximum number of labels to be returned.public List<Label> getRecentlyUsedLabels(int maxResults)
LabelManagergetRecentlyUsedLabels in interface LabelManagermaxResults - is the maximum number of labels to be returned.public List<Label> getRecentlyUsedLabels()
LabelManagergetRecentlyUsedLabels in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNTpublic List<Label> getRecentlyUsedPersonalLabels(String username)
LabelManagerNote: labels in this list may or may not exist.
The UserHistory can be retrieved from the session via the ActionContext (if using an action) or the Execution Context (DWR)
getRecentlyUsedPersonalLabels in interface LabelManagerusername - the user history from the sessionpublic List<Label> getRecentlyUsedPersonalLabels(String username, int maxResults)
LabelManagerNote: labels in this list may or may not exist.
The UserHistory can be retrieved from the session via the ActionContext (if using an action) or the Execution Context (DWR)
getRecentlyUsedPersonalLabels in interface LabelManagerusername - the user history from the sessionmaxResults - the maximum number of results to return to the userpublic List<Labelling> getRecentlyUsedPersonalLabellings(String username, int maxResults)
getRecentlyUsedPersonalLabellings in interface LabelManagerpublic List<? extends Labelable> getCurrentContentForLabel(Label label)
LabelManagergetCurrentContentForLabel in interface LabelManagerpublic List<? extends Labelable> getContentForAllLabels(Collection<Label> labels, int maxResults, int offset)
getContentForAllLabels in interface LabelManagerpublic PartialList<ContentEntityObject> getContentForLabel(int offset, int maxResults, Label label)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getContentForLabel in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnlabel - label which must appear on ContentEntityObjectspublic PartialList<ContentEntityObject> getContentForAllLabels(int offset, int maxResults, Label... labels)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getContentForAllLabels in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnlabels - labels which must appear on ContentEntityObjectspublic <T extends EditableLabelable> PartialList<T> getForLabel(Class<T> labelableClass, int offset, int maxResults, Label label)
LabelManagerContentEntityObjects in the Trash *will* be returned.
getForLabel in interface LabelManagerlabelableClass - the type of labelable to return. Use one of these values:
offset - the offset into the resultsmaxResults - the maximum number of results to returnlabel - label which must appear on labelablespublic <T extends EditableLabelable> PartialList<T> getForLabels(Class<T> labelableClass, int offset, int maxResults, Label... labels)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getForLabels in interface LabelManagerlabelableClass - the type of labelable to return. Use one of these values:
offset - the offset into the resultsmaxResults - the maximum number of results to returnlabels - labels which must all appear on labelablespublic PartialList<EditableLabelable> getForLabels(int offset, int maxResults, Label... labels)
LabelManagerContentEntityObjects in the Trash *will* be returned.
getForLabels in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnlabels - labels which must all appear on labelablespublic PartialList<ContentEntityObject> getContentInSpaceForLabel(int offset, int maxResults, String spaceKey, Label label)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getContentInSpaceForLabel in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnspaceKey - the key of the space to search content inlabel - label which must appear on ContentEntityObjectspublic PartialList<ContentEntityObject> getContentInSpaceForAllLabels(int offset, int maxResults, String spaceKey, Label... labels)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getContentInSpaceForAllLabels in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnspaceKey - the key of the space to search content inlabels - labels which must appear on ContentEntityObjectspublic PartialList<ContentEntityObject> getContentInSpacesForAllLabels(int offset, int maxResults, Set<String> spaceKeys, Label... labels)
LabelManagerContentEntityObjects in the Trash will *not* be returned.
getContentInSpacesForAllLabels in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnspaceKeys - the keys of the spaces to search content inlabels - labels which must appear on ContentEntityObjectspublic PartialList<ContentEntityObject> getAllContentForLabel(int offset, int maxResults, Label label)
LabelManagerContentEntityObjects in the Trash *will* be returned.
getAllContentForLabel in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnlabel - label which must appear on ContentEntityObjectspublic PartialList<ContentEntityObject> getAllContentForAllLabels(int offset, int maxResults, Label... labels)
LabelManagerContentEntityObjects in the Trash *will* be returned.
getAllContentForAllLabels in interface LabelManageroffset - the offset into the resultsmaxResults - the maximum number of results to returnlabels - labels which must appear on ContentEntityObjectspublic List<? extends Labelable> getCurrentContentForLabelAndSpace(Label label, String spaceKey)
LabelManagergetCurrentContentForLabelAndSpace in interface LabelManagerpublic List<? extends Labelable> getCurrentContentWithPersonalLabel(String username)
LabelManagergetCurrentContentWithPersonalLabel in interface LabelManagerpublic List<Space> getSpacesWithLabel(Label label)
LabelManagergetSpacesWithLabel in interface LabelManagerpublic boolean deleteLabel(long id)
LabelManagerdeleteLabel in interface LabelManagerpublic List<Space> getFavouriteSpaces(String username)
getFavouriteSpaces in interface LabelManagerusername - username of label ownerpublic List<Labelling> getFavouriteLabellingsByContentIds(Collection<ContentId> contentIds, com.atlassian.sal.api.user.UserKey userKey)
LabelManagergetFavouriteLabellingsByContentIds in interface LabelManagercontentIds - the contentIds to get favourite labellings foruserKey - the key of the user to get favourite labellings forpublic boolean deleteLabel(Label label)
LabelManagerNOTE: The specified label does note need to be the persistent instance of the label, it simply needs to uniquely identify the label.
deleteLabel in interface LabelManagerpublic Label getLabel(ParsedLabelName parsedLabelName)
LabelManagergetLabel in interface LabelManagerfor details on the format of the labelReference parameter.public Label getLabel(String unparsedLabelName)
LabelManagergetLabel in interface LabelManagerunparsedLabelName - - example - my:foopublic List<Label> getLabels(Collection<String> unparsedLabelNames)
LabelManagergetLabels in interface LabelManagerunparsedLabelNames - - example - my:foo, barpublic Label getLabel(Label label)
LabelManagergetLabel in interface LabelManagerpublic Label getLabel(String labelName, Namespace namespace)
LabelManagergetLabel in interface LabelManagerlabelName - The label namenamespace - The namespace of the labelpublic List<Label> getLabelsByDetail(String labelName, String namespace, String spaceKey, String owner)
LabelManagergetLabelsByDetail in interface LabelManagerlabelName - The name of the label (null to ignore)namespace - The namespace of the labels (null to ignore)spaceKey - The spaceKey to restrict by (null to ignore)owner - The owner of the labels (null to ignore)public List<Label> getLabelsInSpace(String key)
LabelManagergetLabelsInSpace in interface LabelManagerkey - public List<Label> getLabelsInSpace(String key, LimitedRequest limitedRequest)
LabelManagerInternalgetLabelsInSpace in interface LabelManagerInternalpublic long getTotalLabelInSpace(String key)
LabelManagerInternalgetTotalLabelInSpace in interface LabelManagerInternalpublic List<LabelSearchResult> getMostPopularLabels()
LabelManagergetMostPopularLabels in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNT,
LabelSearchResultpublic List<LabelSearchResult> getMostPopularLabels(int count)
LabelManagerThis function does not return the labels itself, but wrapped into a search result with a count!
getMostPopularLabels in interface LabelManagercount - is the maximum number of labels to be returned.LabelSearchResultpublic List<LabelSearchResult> getMostPopularLabelsInSpace(String key)
LabelManagerThis function does not return the labels itself, but wrapped into a search result with a count!
getMostPopularLabelsInSpace in interface LabelManagerkey - the space keyLabelManager.DEFAULT_LABEL_COUNT,
LabelSearchResultpublic List<LabelSearchResult> getMostPopularLabelsInSpace(String key, int count)
LabelManagerThis function does not return the labels itself, but wrapped into a search result with a count!
getMostPopularLabelsInSpace in interface LabelManagerkey - is the space keycount - is the maximum number of labels to be returned.LabelSearchResultpublic Set<RankedLabelSearchResult> getMostPopularLabelsWithRanks(Comparator<? super RankedLabelSearchResult> comparator)
LabelManagergetMostPopularLabelsWithRanks in interface LabelManagerLabelManager.DEFAULT_LABEL_COUNT,
RankedLabelSearchResultpublic Set<RankedLabelSearchResult> getMostPopularLabelsWithRanks(int maxResults, Comparator<? super RankedLabelSearchResult> comparator)
LabelManagerThis function does not return the labels itself, but wrapped into a search result with a count!
getMostPopularLabelsWithRanks in interface LabelManagermaxResults - is the maximum number of labels to be returned.RankedLabelSearchResultpublic Set<RankedLabelSearchResult> getMostPopularLabelsWithRanksInSpace(String key, int maxResults, Comparator<? super RankedLabelSearchResult> comparator)
LabelManagerThis function does not return the labels itself, but wrapped into a search result with a count!
getMostPopularLabelsWithRanksInSpace in interface LabelManagerkey - is the space keymaxResults - is the maximum number of labels to be returned.RankedLabelSearchResultpublic List getContent(Label label)
LabelManagergetContent in interface LabelManagerpublic int getContentCount(Label label)
getContentCount in interface LabelManagerpublic Label createLabel(Label label)
createLabel in interface LabelManagerpublic List<Labelling> getRecentlyUsedLabellings(int maxResults)
getRecentlyUsedLabellings in interface LabelManagerpublic List<Labelling> getRecentlyUsedLabellingsInSpace(String spaceKey, int maxResults)
getRecentlyUsedLabellingsInSpace in interface LabelManagerpublic PageResponse<Label> findGlobalLabelsByNamePrefix(String namePrefix, LimitedRequest pageRequest)
LabelManagerInternalfindGlobalLabelsByNamePrefix in interface LabelManagerInternalpublic PageResponse<Label> findTeamLabelsByNamePrefix(String namePrefix, LimitedRequest pageRequest)
LabelManagerInternalfindTeamLabelsByNamePrefix in interface LabelManagerInternalpublic List<LiteLabelSearchResult> getMostPopularLabelsInSpaceLite(String spaceKey, int maxResults)
getMostPopularLabelsInSpaceLite in interface LabelManagerspaceKey - - space keymaxResults - - limitpublic List<LiteLabelSearchResult> getMostPopularLabelsInSiteLite(int maxResults)
getMostPopularLabelsInSiteLite in interface LabelManagermaxResults - - max resultspublic Set<RankedLiteLabelSearchResult> calculateRanksForLiteLabels(List<LiteLabelSearchResult> labelList, Comparator<? super RankedLiteLabelSearchResult> comparator)
calculateRanksForLiteLabels in interface LabelManagerlabelList - - list of labelscomparator - - comparatorCopyright © 2003–2022 Atlassian. All rights reserved.