@Override @SuppressWarnings("unchecked") public void setAttribute(String attribute, Object value) throws IOException { if (attribute.equals(PERMISSIONS_NAME)) { setPermissions((Set<PosixFilePermission>) value); return; } if (attribute.equals(OWNER_NAME)) { setOwner((UserPrincipal) value); return; } if (attribute.equals(GROUP_NAME)) { setGroup((GroupPrincipal) value); return; } super.setAttribute(attribute, value); }