public final class AccessPermission extends Object
Modifier and Type | Method and Description |
---|---|
char |
getFlag()
Persistent flag that identifies this permission.
|
String |
getFlagString()
Persistent flag that identifies this permission.
|
static AccessPermission |
getHidden()
Factory method specifying that a resource can neither be modified nor displayed.
|
static AccessPermission |
getHidden(UserMessage aReason)
Factory method specifying that a resource can not be modified
and is not displayed.
|
String |
getLabel()
Returns a developer-friendly string label.
|
static AccessPermission |
getReadOnly()
Factory method specifying that a resource can be displayed but not modified.
|
static AccessPermission |
getReadOnly(UserMessage aReason)
Factory method specifying that a resource can be displayed but it cannot modified.
|
UserMessage |
getReadOnlyReason()
Optionally defined if this state is set as 'readOnly' or as 'hidden' and a specific reason is provided.
|
static AccessPermission |
getReadWrite()
Factory method specifying that a resource can be displayed and modified.
|
boolean |
isHidden() |
boolean |
isReadOnly() |
boolean |
isReadWrite() |
AccessPermission |
max(AccessPermission anotherPermission)
Returns the least restrictive permission between this instance and the instance given
as an argument.
|
AccessPermission |
min(AccessPermission anotherPermission)
Returns the most restrictive permission between this instance and the instance given
as an argument.
|
static AccessPermission |
parseFlag(char accessFlag)
Factory method.
|
static AccessPermission |
parseFlag(String accessFlag)
Factory method.
|
String |
toString() |
public static AccessPermission parseFlag(String accessFlag)
getFlagString()
returns the specified argument.parseFlag(char)
public static AccessPermission parseFlag(char accessFlag)
getFlag()
returns the specified argument.parseFlag(String)
public static AccessPermission getReadWrite()
public static AccessPermission getReadOnly()
public static AccessPermission getReadOnly(UserMessage aReason)
Warning: the message is not always displayed in the current version of EBX®.
public static AccessPermission getHidden()
public static AccessPermission getHidden(UserMessage aReason)
The reason specified will be exploited in a future release.
public boolean isReadWrite()
public boolean isReadOnly()
public boolean isHidden()
public UserMessage getReadOnlyReason()
getHidden(UserMessage)
,
getReadOnly(UserMessage)
public AccessPermission min(AccessPermission anotherPermission)
public AccessPermission max(AccessPermission anotherPermission)
public char getFlag()
public String getFlagString()
It returns the same content as getFlag()
.
public String getLabel()