public static class LabelPermission.WithValue extends Object implements ChangePermissionOrLabel
LabelPermission
at a specific value.Constructor and Description |
---|
WithValue(LabelPermission.ForUser forUser,
LabelType type,
LabelValue value)
Construct a reference to a label at a specific value.
|
WithValue(LabelPermission.ForUser forUser,
LabelType type,
short value)
Construct a reference to a label at a specific value.
|
WithValue(LabelPermission.ForUser forUser,
LabelVote label)
Construct a reference to a label at a specific value.
|
WithValue(LabelPermission.ForUser forUser,
String name,
short value)
Construct a reference to a label at a specific value.
|
WithValue(LabelType type,
LabelValue value)
Construct a reference to a label at a specific value.
|
WithValue(LabelType type,
short value)
Construct a reference to a label at a specific value.
|
WithValue(LabelVote label)
Construct a reference to a label at a specific value.
|
WithValue(String name,
short value)
Construct a reference to a label at a specific value.
|
Modifier and Type | Method and Description |
---|---|
String |
describeForException()
A description in the context of an exception message.
|
boolean |
equals(Object other) |
LabelPermission.ForUser |
forUser() |
int |
hashCode() |
String |
label() |
String |
toString() |
short |
value() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
describeEnumValue
public WithValue(LabelType type, LabelValue value)
type
- description of the label.value
- numeric score assigned to the label.public WithValue(LabelType type, short value)
type
- description of the label.value
- numeric score assigned to the label.public WithValue(LabelPermission.ForUser forUser, LabelType type, LabelValue value)
forUser
- SELF
(default) or ON_BEHALF_OF
for labelAs behavior.type
- description of the label.value
- numeric score assigned to the label.public WithValue(LabelPermission.ForUser forUser, LabelType type, short value)
forUser
- SELF
(default) or ON_BEHALF_OF
for labelAs behavior.type
- description of the label.value
- numeric score assigned to the label.public WithValue(String name, short value)
name
- name of the label, e.g. "Code-Review"
or "Verified"
.value
- numeric score assigned to the label.public WithValue(LabelPermission.ForUser forUser, String name, short value)
forUser
- SELF
(default) or ON_BEHALF_OF
for labelAs behavior.name
- name of the label, e.g. "Code-Review"
or "Verified"
.value
- numeric score assigned to the label.public WithValue(LabelVote label)
label
- label name and vote.public WithValue(LabelPermission.ForUser forUser, LabelVote label)
forUser
- SELF
(default) or ON_BEHALF_OF
for labelAs behavior.label
- label name and vote.public LabelPermission.ForUser forUser()
SELF
or ON_BEHALF_OF
(or labelAs).public String label()
"Code-Review"
.public short value()
public String describeForException()
GerritPermission
Should be grammatical when used in the construction "not permitted: [description] on
[resource]", although individual PermissionBackend
implementations may vary the
wording.
describeForException
in interface GerritPermission