PosixFilePermission or the traditional Unix mode representation of
permissions.
| Modifier and Type | Class and Description |
|---|---|
| public static enum | PermissionUtils.FileType
The supported types of files, maps to the |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| private static void | |
| public static Set | Returns: the permissionsthe resource to read permissions from r, Function<Path, Set<PosixFilePermission>> optional fallback function to provide
permissions for file system that don't support
PosixFilePermissions. The Path corresponding to the file is
passed to the callback. posixNotSupportedFallback)Sets permissions of a |
| public static int | Returns: the "mode"the permissions permissions, PermissionUtils.the file type typeTranslates a set of permissions into a Unix stat(2) |
| private static long | |
| public static Set | Returns: set of permissionsthe "mode" mode)Translates a Unix stat(2) |
| public static void | setPermissions(Resource
the resource to set permissions for r, Set<PosixFilePermission> the permissions permissions, Consumer<Path> optional callback that is
invoked for a file provider resource if the file-system holding
the file doesn't support PosixFilePermissions. The Path
corresponding to the file is passed to the callback. posixNotSupportedCallback)Sets permissions on a |
| PermissionUtils | back to summary |
|---|---|
| private PermissionUtils() | |
| addPermissions | back to summary |
|---|---|
| private static void addPermissions(Set<PosixFilePermission> permissions, String prefix, long mode) | |
| getPermissions | back to summary |
|---|---|
| public static Set Sets permissions of a Supported types are:
| |
| modeFromPermissions | back to summary |
|---|---|
| public static int modeFromPermissions(Set<PosixFilePermission> permissions, PermissionUtils. Translates a set of permissions into a Unix stat(2)
| |
| modeFromPermissions | back to summary |
|---|---|
| private static long modeFromPermissions(Set<PosixFilePermission> permissions, String prefix) | |
| permissionsFromMode | back to summary |
|---|---|
| public static Set Translates a Unix stat(2)
| |
| setPermissions | back to summary |
|---|---|
| public static void setPermissions(Resource r, Set<PosixFilePermission> permissions, Consumer<Path> posixNotSupportedCallback) throws IOException Sets permissions on a Supported types are:
| |
isFoo methods
in java.nio.file.attribute.BasicFileAttributes .
| Modifier and Type | Field and Description |
|---|---|
| public static final PermissionUtils. | DIR
A directory. |
| public static final PermissionUtils. | OTHER
Something that is neither a regular file nor a directory nor a symbolic link. |
| public static final PermissionUtils. | REGULAR_FILE
A regular file. |
| public static final PermissionUtils. | SYMLINK
A symbolic link. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static PermissionUtils. | |
| public static PermissionUtils. | |
| public static PermissionUtils. | |
| public static PermissionUtils. |
| DIR | back to summary |
|---|---|
| public static final PermissionUtils. A directory. | |
| OTHER | back to summary |
|---|---|
| public static final PermissionUtils. Something that is neither a regular file nor a directory nor a symbolic link. | |
| REGULAR_FILE | back to summary |
|---|---|
| public static final PermissionUtils. A regular file. | |
| SYMLINK | back to summary |
|---|---|
| public static final PermissionUtils. A symbolic link. | |
| FileType | back to summary |
|---|---|
| private FileType() | |
| of | back to summary |
|---|---|
| public static PermissionUtils. Determines the file type of a
| |
| of | back to summary |
|---|---|
| public static PermissionUtils. Determines the file type of a
| |
| valueOf | back to summary |
|---|---|
| public static PermissionUtils. | |
| values | back to summary |
|---|---|
| public static PermissionUtils. | |