public abstract class

AbstractLabelableEntityObject

extends AbstractVersionedEntityObject
implements EditableLabelable
java.lang.Object
   ↳ com.atlassian.core.bean.EntityObject
     ↳ com.atlassian.confluence.core.ConfluenceEntityObject
       ↳ com.atlassian.confluence.core.AbstractVersionedEntityObject
         ↳ com.atlassian.confluence.core.AbstractLabelableEntityObject
Known Direct Subclasses
Known Indirect Subclasses

Summary

[Expand]
Inherited Constants
From class com.atlassian.confluence.core.AbstractVersionedEntityObject
Public Constructors
AbstractLabelableEntityObject()
Public Methods
void addLabelling(Labelling content)
Object clone()
List<Label> getGlobalLabels(User user)
List the labels on this content that are global labels
int getLabelCount()
Get the number of labels that are associated with this object.
LabelUtil getLabelUtil()
List<Labelling> getLabellings()
List<Label> getLabels()
Retrieve the labels that are associated with this object.
List<Label> getLabelsForDisplay(User user)
List the labels on this content that are visible to a particular user, and should be shown in a list of labels.
List<Label> getPersonalLabels(User user)
List the labels on this content that are personal labels for a particular user
List<Label> getTeamLabels(User user)
List the labels on this content that are team labels for a particular user
List<Label> getVisibleLabels(User user)
List the labels on this content that are visible to a particular user
boolean isFavourite(User user)
Is this object marked as somebody's favourite?
void removeLabelling(Labelling labelling)
Protected Methods
void setLabellings(List<Labelling> labellings)
[Expand]
Inherited Methods
From class com.atlassian.confluence.core.AbstractVersionedEntityObject
From class com.atlassian.confluence.core.ConfluenceEntityObject
From class com.atlassian.core.bean.EntityObject
From class java.lang.Object
From interface com.atlassian.confluence.core.Versioned
From interface com.atlassian.confluence.labels.EditableLabelable
From interface com.atlassian.confluence.labels.Labelable

Public Constructors

public AbstractLabelableEntityObject ()

Public Methods

public void addLabelling (Labelling content)

public Object clone ()

public List<Label> getGlobalLabels (User user)

List the labels on this content that are global labels

Parameters
user the user
Returns
  • the personal labels on this content visible to the user

public int getLabelCount ()

Get the number of labels that are associated with this object.

Returns
  • the number of labels associated with this object.

public LabelUtil getLabelUtil ()

public List<Labelling> getLabellings ()

public List<Label> getLabels ()

Retrieve the labels that are associated with this object.

Returns
  • a list of label instances.

public List<Label> getLabelsForDisplay (User user)

List the labels on this content that are visible to a particular user, and should be shown in a list of labels. This is like {code}getVisibleLabels{code} except that it also filters out special labels like favourites

Parameters
user the user
Returns
  • the labels on this content visible to that user

public List<Label> getPersonalLabels (User user)

List the labels on this content that are personal labels for a particular user

Parameters
user the user
Returns
  • the personal labels on this content visible to the user

public List<Label> getTeamLabels (User user)

List the labels on this content that are team labels for a particular user

Parameters
user the user
Returns
  • the team labels on this content visible to the user

public List<Label> getVisibleLabels (User user)

List the labels on this content that are visible to a particular user

Parameters
user the user
Returns
  • the labels on this content visible to that user

public boolean isFavourite (User user)

Is this object marked as somebody's favourite?

Parameters
user the user who is being checked against. If user is null this method must always return false (anonymous users can not mark anything as a favourite, obviously)
Returns
  • true if the labelable object is a 'favourite' of a given user, false otherwise

public void removeLabelling (Labelling labelling)

Protected Methods

protected void setLabellings (List<Labelling> labellings)