RolePermissions Class
- java.
lang. Object - com.
azure. storage. file. datalake. models. RolePermissions
- com.
public class RolePermissions
Represents the POSIX-style permissions on given resource for an arbitrary role. Each role can have any combination of read, write, and execute permissions. Manipulating resource permissions is only supported when ADLS interop and Hierarchical Namespace are enabled.
Constructor Summary
Constructor | Description |
---|---|
RolePermissions() |
Initializes an instance of |
Method Summary
Modifier and Type | Method and Description |
---|---|
boolean | equals(Object o) |
boolean | hasExecutePermission() |
boolean | hasReadPermission() |
boolean | hasWritePermission() |
int | hashCode() |
static
Role |
parseOctal(int octal)
Convert an octal representation of permissions for a given role into an |
static
Role |
parseSymbolic(String str, boolean allowStickyBit)
Convert a symbolic representation of permissions for a given role into an |
Role |
setExecutePermission(boolean hasExecutePermission)
Sets the execute permission status. |
Role |
setReadPermission(boolean hasReadPermission)
Sets the read permission status. |
Role |
setWritePermission(boolean hasWritePermission)
Sets the write permission status. |
String |
toOctal()
Converts the |
String |
toSymbolic()
Converts the |
Methods inherited from java.lang.Object
Constructor Details
RolePermissions
public RolePermissions()
Initializes an instance of RolePermissions
with all values set to false.
Method Details
equals
public boolean equals(Object o)
Overrides:
RolePermissions.equals(Object o)Parameters:
hasExecutePermission
public boolean hasExecutePermission()
Returns:
hasReadPermission
public boolean hasReadPermission()
Returns:
hasWritePermission
public boolean hasWritePermission()
Returns:
hashCode
public int hashCode()
Overrides:
RolePermissions.hashCode()parseOctal
public static RolePermissions parseOctal(int octal)
Convert an octal representation of permissions for a given role into an RolePermissions
instance.
Parameters:
Returns:
parseSymbolic
public static RolePermissions parseSymbolic(String str, boolean allowStickyBit)
Convert a symbolic representation of permissions for a given role into an RolePermissions
instance.
Parameters:
String
representing full permissions for a
resource.
Returns:
setExecutePermission
public RolePermissions setExecutePermission(boolean hasExecutePermission)
Sets the execute permission status.
Parameters:
Returns:
setReadPermission
public RolePermissions setReadPermission(boolean hasReadPermission)
Sets the read permission status.
Parameters:
Returns:
setWritePermission
public RolePermissions setWritePermission(boolean hasWritePermission)
Sets the write permission status.
Parameters:
Returns:
toOctal
public String toOctal()
Converts the RolePermissions
instance into its octal representation.
Returns:
String
representation of the permissions.toSymbolic
public String toSymbolic()
Converts the RolePermissions
instance into its symbolic representation.
Returns:
String
representation of the permission.Applies to
Azure SDK for Java