Package org.eclipse.serializer.afs.types
Class AFile.Wrapper.Abstract<U>
- java.lang.Object
-
- org.eclipse.serializer.afs.types.AItem.Base
-
- org.eclipse.serializer.afs.types.AFile.Wrapper.Abstract<U>
-
- All Implemented Interfaces:
AFile,AFile.Wrapper,AItem,AItem.Wrapper
- Enclosing interface:
- AFile.Wrapper
public abstract static class AFile.Wrapper.Abstract<U> extends AItem.Base implements AFile.Wrapper
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eclipse.serializer.afs.types.AFile
AFile.Default, AFile.Observer, AFile.Wrapper
-
Nested classes/interfaces inherited from interface org.eclipse.serializer.afs.types.AFile.Wrapper
AFile.Wrapper.Abstract<U>
-
Nested classes/interfaces inherited from interface org.eclipse.serializer.afs.types.AItem
AItem.Abstract, AItem.Base, AItem.Wrapper
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AFileactual()booleanexists()Queries whether the item represented by this instance actually physically exists on the underlying storage layer.AFileSystemfileSystem()Stringidentifier()The value that uniquely identifies the item locally in itsAItem.parent()directory.<C extends Consumer<? super AFile.Observer>>
CiterateObservers(C logic)protected Objectmutex()Stringname()A simple String representing the "name" of the file.ADirectoryparent()The directory (identifying container) in which this item is located and in which no other item can have the sameAItem.identifier()as this item.booleanregisterObserver(AFile.Observer observer)booleanremoveObserver(AFile.Observer observer)Stringtype()An optional String defining the type of the file's content.Uuser()-
Methods inherited from class org.eclipse.serializer.afs.types.AItem.Base
toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.eclipse.serializer.afs.types.AFile
defaultUser, ensureExists, isEmpty, isUsed, size, toPath, toPathString, tryUseReading, tryUseReading, tryUseWriting, tryUseWriting, useReading, useReading, useWriting, useWriting
-
-
-
-
Method Detail
-
mutex
protected Object mutex()
-
user
public U user()
- Specified by:
userin interfaceAItem.Wrapper
-
actual
public AFile actual()
- Specified by:
actualin interfaceAFile.Wrapper- Specified by:
actualin interfaceAItem.Wrapper
-
fileSystem
public AFileSystem fileSystem()
- Specified by:
fileSystemin interfaceAItem
-
registerObserver
public boolean registerObserver(AFile.Observer observer)
- Specified by:
registerObserverin interfaceAFile
-
removeObserver
public boolean removeObserver(AFile.Observer observer)
- Specified by:
removeObserverin interfaceAFile
-
iterateObservers
public <C extends Consumer<? super AFile.Observer>> C iterateObservers(C logic)
- Specified by:
iterateObserversin interfaceAFile
-
parent
public ADirectory parent()
Description copied from interface:AItemThe directory (identifying container) in which this item is located and in which no other item can have the sameAItem.identifier()as this item.- Specified by:
parentin interfaceAItem- Returns:
- the item's parent directory.
- See Also:
AItem.identifier(),AItem.toPathString()
-
identifier
public String identifier()
Description copied from interface:AItemThe value that uniquely identifies the item locally in itsAItem.parent()directory.- Specified by:
identifierin interfaceAItem- Returns:
- the item's locally unique identifier.
- See Also:
AItem.parent(),AItem.toPathString()
-
name
public String name()
Description copied from interface:AFileA simple String representing the "name" of the file. While no two files can have the sameAItem.identifier()inside a given directory, any number of files can have the same name.Depending on the file system implementation,
AFile.name()might be the same value asAItem.identifier(), but whileAItem.identifier()is guaranteed to be a unique local identifier for any file system,AFile.name()is not.- Specified by:
namein interfaceAFile- Returns:
- the file's name.
- See Also:
AFile.toPathString(),AItem.identifier(),AFile.type()
-
type
public String type()
Description copied from interface:AFileAn optional String defining the type of the file's content.If such an information makes no sense for a certain file system, this value may be
null.
-
-