@Override
  public void set(File file, String view, String attribute, Object value, boolean create) {
    switch (attribute) {
      case "group":
        checkNotCreate(view, attribute, create);

        GroupPrincipal group = checkType(view, attribute, value, GroupPrincipal.class);
        if (!(group instanceof UserLookupService.JimfsGroupPrincipal)) {
          group = createGroupPrincipal(group.getName());
        }
        file.setAttribute("posix", "group", group);
        break;
      case "permissions":
        file.setAttribute(
            "posix", "permissions", toPermissions(checkType(view, attribute, value, Set.class)));
        break;
      default:
    }
  }
Attribute provider that provides the {@link PosixFileAttributeView} ("posix") and allows reading
of {@link PosixFileAttributes}.

@author Colin Decker
jimfs/src/main/java/com/google/common/jimfs/PosixAttributeProvider.java