public static interface AbstractFileSystem.Attr extends Serializable
| Modifier and Type | Field and Description |
|---|---|
static long |
serialVersionUID
Deprecated.
Only public by accident.
|
| Modifier and Type | Method and Description |
|---|---|
Enumeration<String> |
attributes(String name)
Get all file attribute names for the file.
|
void |
deleteAttributes(String name)
Called when a file is deleted, to also delete its attributes.
|
Object |
readAttribute(String name,
String attrName)
Get the file attribute with the specified name.
|
void |
renameAttributes(String oldName,
String newName)
Called when a file is renamed, to appropriately update its attributes.
|
void |
writeAttribute(String name,
String attrName,
Object value)
Set the file attribute with the specified name.
|
@Deprecated static final long serialVersionUID
Object readAttribute(String name, 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(String name, String attrName, Object value) throws 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.IOException - if the attribute cannot be set. If serialization is used to store it, this may in fact be a subclass such as NotSerializableException.Enumeration<String> attributes(String name)
name - the filevoid renameAttributes(String oldName, String newName)
oldName - old name of the filenewName - new name of the filevoid deleteAttributes(String name)
name - name of the file