| Modifier and Type | Class and Description |
|---|---|
| pack-priv static class | |
| pack-priv static class | |
| pack-priv static class |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv static UnixFileAttributeViews. | |
| pack-priv static FileOwnerAttributeViewImpl | |
| pack-priv static UnixFileAttributeViews. | |
| pack-priv static UnixFileAttributeViews. |
| UnixFileAttributeViews | back to summary |
|---|---|
| pack-priv UnixFileAttributeViews() | |
| createBasicView | back to summary |
|---|---|
| pack-priv static UnixFileAttributeViews. | |
| createOwnerView | back to summary |
|---|---|
| pack-priv static FileOwnerAttributeViewImpl createOwnerView(UnixPath file, boolean followLinks) | |
| createPosixView | back to summary |
|---|---|
| pack-priv static UnixFileAttributeViews. | |
| createUnixView | back to summary |
|---|---|
| pack-priv static UnixFileAttributeViews. | |
| Modifier and Type | Field and Description |
|---|---|
| protected final UnixPath | |
| protected final boolean |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public BasicFileAttributes | readAttributes()
Implements java. Reads the basic file attributes as a bulk operation. |
| public void | setTimes(FileTime lastModifiedTime, FileTime lastAccessTime, FileTime createTime)
Implements java. Updates any or all of the file's last modified time, last access time, and create time attributes. |
| file | back to summary |
|---|---|
| protected final UnixPath file | |
| followLinks | back to summary |
|---|---|
| protected final boolean followLinks | |
| Basic | back to summary |
|---|---|
| pack-priv Basic(UnixPath file, boolean followLinks) | |
| readAttributes | back to summary |
|---|---|
| public BasicFileAttributes readAttributes() throws IOException Implements java. Doc from java. Reads the basic file attributes as a bulk operation. It is implementation specific if all file attributes are read as an atomic operation with respect to other file system operations.
| |
| setTimes | back to summary |
|---|---|
| public void setTimes(FileTime lastModifiedTime, FileTime lastAccessTime, FileTime createTime) throws IOException Implements java. Doc from java. Updates any or all of the file's last modified time, last access time, and create time attributes. This method updates the file's timestamp attributes. The values are
converted to the epoch and precision supported by the file system.
Converting from finer to coarser granularities results in precision loss.
The behavior of this method when attempting to set a timestamp that is
not supported or to a value that is outside the range supported by the
underlying file store is not defined. It may or not fail by throwing an
If any of the Usage Example: Suppose we want to change a file's last access time. Path path = ... FileTime time = ... Files.getFileAttributeView(path, BasicFileAttributeView.class).setTimes(null, time, null);
| |
| Modifier and Type | Field and Description |
|---|---|
| private static final String | |
| private static final String | |
| private static final String | |
| pack-priv static final Set |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| GROUP_NAME | back to summary |
|---|---|
| private static final String GROUP_NAME | |
| OWNER_NAME | back to summary |
|---|---|
| private static final String OWNER_NAME | |
| PERMISSIONS_NAME | back to summary |
|---|---|
| private static final String PERMISSIONS_NAME | |
| posixAttributeNames | back to summary |
|---|---|
| pack-priv static final Set<String> posixAttributeNames | |
| Posix | back to summary |
|---|---|
| pack-priv Posix(UnixPath file, boolean followLinks) | |
| addRequestedPosixAttributes | back to summary |
|---|---|
| pack-priv final void addRequestedPosixAttributes(PosixFileAttributes attrs, AbstractBasicFileAttributeView. Invoked by readAttributes or sub-classes to add all matching posix attributes to the builder | |
| getOwner | back to summary |
|---|---|
| public UserPrincipal getOwner() throws IOException Implements java. Doc from java. Read the file owner. It is implementation specific if the file owner can be a
| |
| name | back to summary |
|---|---|
| public String name() Overrides sun. Implements java. Doc from java. Returns the name of the attribute view. Attribute views of this type
have the name
| |
| readAttributes | back to summary |
|---|---|
| public Map Overrides sun. Implements sun. Doc from sun. Reads a set of file attributes as a bulk operation.
| |
| readAttributes | back to summary |
|---|---|
| public UnixFileAttributes readAttributes() throws IOException Overrides sun. Implements java. Doc from java. Reads the basic file attributes as a bulk operation. It is implementation specific if all file attributes are read as an atomic operation with respect to other file system operations.
| |
| setAttribute | back to summary |
|---|---|
| public void setAttribute(String attribute, Object value) throws IOException Overrides sun. Implements sun. Doc from sun. Sets/updates the value of an attribute.
| |
| setGroup | back to summary |
|---|---|
| public void setGroup(GroupPrincipal group) throws IOException Implements java. Doc from java. Updates the file group-owner.
| |
| setMode | back to summary |
|---|---|
| pack-priv final void setMode(int mode) throws IOException | |
| setOwner | back to summary |
|---|---|
| public void setOwner(UserPrincipal owner) throws IOException Implements java. Doc from java. Updates the file owner. It is implementation specific if the file owner can be a
| |
| setOwners | back to summary |
|---|---|
| pack-priv final void setOwners(int uid, int gid) throws IOException | |
| setPermissions | back to summary |
|---|---|
| public void setPermissions(Set<PosixFilePermission> perms) throws IOException Implements java. Doc from java. Updates the file permissions.
| |
| Modifier and Type | Field and Description |
|---|---|
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| pack-priv static final Set |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public String | name()
Overrides sun. Implements java. Returns the name of the attribute view. |
| public Map | readAttributes(String[] requested)
Overrides sun. Implements sun. Reads a set of file attributes as a bulk operation. |
| public void | setAttribute(String attribute, Object value)
Overrides sun. Implements sun. Sets/updates the value of an attribute. |
| CTIME_NAME | back to summary |
|---|---|
| private static final String CTIME_NAME | |
| DEV_NAME | back to summary |
|---|---|
| private static final String DEV_NAME | |
| GID_NAME | back to summary |
|---|---|
| private static final String GID_NAME | |
| INO_NAME | back to summary |
|---|---|
| private static final String INO_NAME | |
| MODE_NAME | back to summary |
|---|---|
| private static final String MODE_NAME | |
| NLINK_NAME | back to summary |
|---|---|
| private static final String NLINK_NAME | |
| RDEV_NAME | back to summary |
|---|---|
| private static final String RDEV_NAME | |
| UID_NAME | back to summary |
|---|---|
| private static final String UID_NAME | |
| unixAttributeNames | back to summary |
|---|---|
| pack-priv static final Set<String> unixAttributeNames | |
| Unix | back to summary |
|---|---|
| pack-priv Unix(UnixPath file, boolean followLinks) | |
| name | back to summary |
|---|---|
| public String name() Overrides sun. Implements java. Doc from java. Returns the name of the attribute view. Attribute views of this type
have the name
| |
| readAttributes | back to summary |
|---|---|
| public Map Overrides sun. Implements sun. Doc from sun. Reads a set of file attributes as a bulk operation.
| |
| setAttribute | back to summary |
|---|---|
| public void setAttribute(String attribute, Object value) throws IOException Overrides sun. Implements sun. Doc from sun. Sets/updates the value of an attribute.
| |