Class FieldRestriction
java.lang.Object
com.deiser.jira.profields.api.field.restriction.FieldRestriction
The type Field restriction.
-
Method Summary
Modifier and TypeMethodDescriptionstatic FieldRestrictionBy group field restriction.static FieldRestrictionbyProjectRole(List<String> editors, List<String> viewers) By project role field restriction.static FieldRestrictionCreate field restriction.static FieldRestrictionempty()Empty field restriction.Gets editors.Gets first editor.Gets first viewer.getType()Gets type.com.deiser.jira.profields.impl.field.wrapper.restriction.RestrictionTypeGets type enum.Gets viewers.booleanHas group restriction boolean.booleanHas project role restriction boolean.booleanHas restrictions boolean.booleanisEmpty()Is empty boolean.voidvalidate(FieldType fieldType, com.deiser.jira.profields.impl.field.wrapper.restriction.validation.FieldRestrictionValidator fieldRestrictionValidator) Validate.
-
Method Details
-
empty
Empty field restriction.- Returns:
- the field restriction
-
create
Create field restriction.- Parameters:
type- the typeeditors- the editorsviewers- the viewers- Returns:
- the field restriction
-
byProjectRole
By project role field restriction.- Parameters:
editors- the editorsviewers- the viewers- Returns:
- the field restriction
-
byGroup
By group field restriction.- Parameters:
editors- the editorsviewers- the viewers- Returns:
- the field restriction
-
isEmpty
public boolean isEmpty()Is empty boolean.- Returns:
- the boolean
-
getType
Gets type.- Returns:
- the type
-
getTypeEnum
public com.deiser.jira.profields.impl.field.wrapper.restriction.RestrictionType getTypeEnum()Gets type enum.- Returns:
- the type enum
-
getEditors
Gets editors.- Returns:
- the editors
-
getViewers
Gets viewers.- Returns:
- the viewers
-
hasProjectRoleRestriction
public boolean hasProjectRoleRestriction()Has project role restriction boolean.- Returns:
- the boolean
-
hasGroupRestriction
public boolean hasGroupRestriction()Has group restriction boolean.- Returns:
- the boolean
-
getFirstEditor
Gets first editor.- Returns:
- the first editor
-
getFirstViewer
Gets first viewer.- Returns:
- the first viewer
-
hasRestrictions
public boolean hasRestrictions()Has restrictions boolean.- Returns:
- the boolean
-
validate
public void validate(FieldType fieldType, com.deiser.jira.profields.impl.field.wrapper.restriction.validation.FieldRestrictionValidator fieldRestrictionValidator) Validate.- Parameters:
fieldType- the field typefieldRestrictionValidator- the field restriction validator
-