类 FilePermissions

java.lang.Object
org.springframework.boot.buildpack.platform.io.FilePermissions

public final class FilePermissions extends Object
Utilities for dealing with file permissions and attributes.
从以下版本开始:
2.5.0
作者:
Scott Frederick
  • 方法详细资料

    • umaskForPath

      public static int umaskForPath(Path path) throws IOException
      Return the integer representation of the file permissions for a path, where the integer value conforms to the umask octal notation.
      参数:
      path - the file path
      返回:
      the integer representation
      抛出:
      IOException - if path permissions cannot be read
    • posixPermissionsToUmask

      public static int posixPermissionsToUmask(Collection<PosixFilePermission> permissions)
      Return the integer representation of a set of Posix file permissions, where the integer value conforms to the umask octal notation.
      参数:
      permissions - the set of PosixFilePermissions
      返回:
      the integer representation