Package org.italiangrid.voms.util
Enum Class FilePermissionHelper.PosixFilePermission
java.lang.Object
java.lang.Enum<FilePermissionHelper.PosixFilePermission>
org.italiangrid.voms.util.FilePermissionHelper.PosixFilePermission
- All Implemented Interfaces:
Serializable
,Comparable<FilePermissionHelper.PosixFilePermission>
,Constable
- Enclosing class:
FilePermissionHelper
public static enum FilePermissionHelper.PosixFilePermission
extends Enum<FilePermissionHelper.PosixFilePermission>
Enumeration representing POSIX file permissions.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionFull permissions for all users (chmod 777, stat -rwxrwxrwx).Full permissions for the user (chmod 700, stat -rwx------).Read-only permission for the user (chmod 400, stat -r--------).Read and write permission for the user (chmod 600, stat -rw-------). -
Method Summary
Modifier and TypeMethodDescriptionGets the chmod-style (numeric) representation of the permission.statForm()
Gets the stat-style (symbolic) representation of the permission.Returns the enum constant of this class with the specified name.values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
USER_RO
Read-only permission for the user (chmod 400, stat -r--------). -
USER_RW
Read and write permission for the user (chmod 600, stat -rw-------). -
USER_ALL
Full permissions for the user (chmod 700, stat -rwx------). -
ALL_PERMS
Full permissions for all users (chmod 777, stat -rwxrwxrwx).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException
- if the argument is null
-
statForm
Gets the stat-style (symbolic) representation of the permission.- Returns:
- the stat-formatted permission string (e.g., "-rw-------").
-
chmodForm
Gets the chmod-style (numeric) representation of the permission.- Returns:
- the chmod-formatted permission string (e.g., "600").
-