java.io.SerializableDefaultAttributes, JarFileSystem.Impl, XMLFileSystem.Implpublic static interface AbstractFileSystem.Attr
extends java.io.Serializable
| Modifier and Type | Field | Description |
|---|---|---|
static long |
serialVersionUID |
Deprecated.
Only public by accident.
|
| Modifier and Type | Method | Description |
|---|---|---|
java.util.Enumeration<java.lang.String> |
attributes(java.lang.String name) |
Get all file attribute names for the file.
|
void |
deleteAttributes(java.lang.String name) |
Called when a file is deleted, to also delete its attributes.
|
java.lang.Object |
readAttribute(java.lang.String name,
java.lang.String attrName) |
Get the file attribute with the specified name.
|
void |
renameAttributes(java.lang.String oldName,
java.lang.String newName) |
Called when a file is renamed, to appropriately update its attributes.
|
void |
writeAttribute(java.lang.String name,
java.lang.String attrName,
java.lang.Object value) |
Set the file attribute with the specified name.
|
@Deprecated static final long serialVersionUID
java.lang.Object readAttribute(java.lang.String name,
java.lang.String attrName)
name - the fileattrName - name of the attributenull if the attribute is unset (or could not be properly restored for some reason)void writeAttribute(java.lang.String name,
java.lang.String attrName,
java.lang.Object value)
throws java.io.IOException
name - the fileattrName - name of the attributevalue - new value or null to clear the attribute. Must be serializable, although particular filesystems may or may not use serialization to store attribute values.java.io.IOException - if the attribute cannot be set. If serialization is used to store it, this may in fact be a subclass such as NotSerializableException.java.util.Enumeration<java.lang.String> attributes(java.lang.String name)
name - the filevoid renameAttributes(java.lang.String oldName,
java.lang.String newName)
oldName - old name of the filenewName - new name of the filevoid deleteAttributes(java.lang.String name)
name - name of the fileBuilt on April 24 2018. | Portions Copyright 1997-2018 Oracle. All rights reserved.