Enum RefPermission
- java.lang.Object
-
- java.lang.Enum<RefPermission>
-
- com.google.gerrit.server.permissions.RefPermission
-
- All Implemented Interfaces:
Serializable
,Comparable<RefPermission>
public enum RefPermission extends Enum<RefPermission>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CREATE
CREATE_CHANGE
Create a change to code review a commit.DELETE
FORCE_UPDATE
FORGE_AUTHOR
FORGE_COMMITTER
FORGE_SERVER
MERGE
READ
SKIP_VALIDATION
UPDATE
UPDATE_BY_SUBMIT
Creates changes, then also immediately submits them duringpush
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
describeForException()
Optional<String>
permissionName()
static RefPermission
valueOf(String name)
Returns the enum constant of this type with the specified name.static RefPermission[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
READ
public static final RefPermission READ
-
CREATE
public static final RefPermission CREATE
-
DELETE
public static final RefPermission DELETE
-
UPDATE
public static final RefPermission UPDATE
-
FORCE_UPDATE
public static final RefPermission FORCE_UPDATE
-
FORGE_AUTHOR
public static final RefPermission FORGE_AUTHOR
-
FORGE_COMMITTER
public static final RefPermission FORGE_COMMITTER
-
FORGE_SERVER
public static final RefPermission FORGE_SERVER
-
MERGE
public static final RefPermission MERGE
-
SKIP_VALIDATION
public static final RefPermission SKIP_VALIDATION
-
CREATE_CHANGE
public static final RefPermission CREATE_CHANGE
Create a change to code review a commit.
-
UPDATE_BY_SUBMIT
public static final RefPermission UPDATE_BY_SUBMIT
Creates changes, then also immediately submits them duringpush
.This is similar to
UPDATE
except it constructs changes first, then submits them according to the submit strategy, which may include cherry-pick or rebase. By creating changes for each commit, automatic server side rebase, and post-update review are enabled.
-
-
Method Detail
-
values
public static RefPermission[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (RefPermission c : RefPermission.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static RefPermission valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
permissionName
public Optional<String> permissionName()
- Returns:
- name used in
project.config
permissions.
-
describeForException
public String describeForException()
-
-