public interface LabelPermissionEnforcer
Modifier and Type | Method and Description |
---|---|
List |
filterLabelsByNamespace(List labelList,
com.atlassian.user.User user,
Namespace namespace)
Takes a list of label objects and filters out those not in the specified namespace
|
List |
filterVisibleLabels(List labelList,
com.atlassian.user.User user,
boolean hideSpecialLabels)
Takes a list of label objects and filters out those not visible to the given user
|
boolean |
isLabelableByUser(Labelable object)
Checks that the object permits labels to be edited by the logged in user.
|
boolean |
userCanEditLabel(Label label,
Labelable object)
Check if the user can edit a label of an object
|
boolean |
userCanEditLabel(ParsedLabelName ref,
Labelable object)
Check if the user can edit a label of an object
|
boolean |
userCanEditLabelOrIsSpaceAdmin(Label label,
SpaceContentEntityObject object)
Check if the user can edit a label of a space object or a space admin
|
boolean |
userCanViewObject(Labelable object)
Check if the user can view the labelable object
|
boolean isLabelableByUser(Labelable object)
object
- - the object to be labelled, if null returns false.boolean userCanEditLabel(ParsedLabelName ref, Labelable object)
ref
- the referen ce to the labelobject
- the object associated with the labelboolean userCanEditLabel(Label label, Labelable object)
label
- the labelobject
- the object associated with the labelboolean userCanEditLabelOrIsSpaceAdmin(Label label, SpaceContentEntityObject object)
label
- the labelobject
- the space objectboolean userCanViewObject(Labelable object)
object
- the labelable objectList filterVisibleLabels(List labelList, com.atlassian.user.User user, boolean hideSpecialLabels)
labelList
- a list of Label objectsuser
- the User the labels are filtered forhideSpecialLabels
- whether to hide special labels, such as favouritesList filterLabelsByNamespace(List labelList, com.atlassian.user.User user, Namespace namespace)
labelList
- a list of Label objectsuser
- the User the labels are filtered fornamespace
- the Namespace to filter byCopyright © 2003–2023 Atlassian. All rights reserved.