Package convex.dlfs.impl
Class DLFSLocal
java.lang.Object
java.nio.file.FileSystem
convex.dlfs.DLFileSystem
convex.dlfs.impl.DLFSLocal
-
Field Summary
Fields inherited from class convex.dlfs.DLFileSystem
emptyPath, provider, root, uriPath
-
Constructor Summary
ConstructorsConstructorDescriptionDLFSLocal
(DLFSProvider dlfsProvider, String uriPath, AVector<ACell> rootNode) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
checkAccess
(DLPath path) Implementation for DLFSProvider delegationclone()
static DLFSLocal
create
(DLFSProvider provider) protected DLPath
createDirectory
(DLPath dir, FileAttribute<?>[] attrs) Implementation for delegation by DLFSProvider, create a directorycreateFile
(DLPath path) Creates a file, returning the new nodevoid
Gets DLFS node for the given pathvoid
Merges another DLFS drive into this onenewByteChannel
(DLPath path, Set<? extends OpenOption> options, FileAttribute<?>[] attrs) Implementation for delegation by DLFSProvidernewDirectoryStream
(DLPath dir, DirectoryStream.Filter<? super Path> filter) Implementation for delegation by DLFSProviderupdateNode
(DLPath dir, AVector<ACell> newNode) Updates a node, returning the new nodeMethods inherited from class convex.dlfs.DLFileSystem
close, getEmptyPath, getFileAttributes, getFileStores, getNodeHash, getPath, getPathMatcher, getRoot, getRootDirectories, getSeparator, getTimestamp, getUserPrincipalLookupService, isOpen, isReadOnly, newWatchService, provider, replicate, setTimestamp, supportedFileAttributeViews, updateTimestamp, updateTimestamp
-
Constructor Details
-
DLFSLocal
-
-
Method Details
-
create
-
getNode
Description copied from class:DLFileSystem
Gets DLFS node for the given path- Specified by:
getNode
in classDLFileSystem
- Parameters:
path
- Path for which to obtain DLFSNode- Returns:
- DLFS node, or null if does not exist
-
newDirectoryStream
public DLDirectoryStream newDirectoryStream(DLPath dir, DirectoryStream.Filter<? super Path> filter) Description copied from class:DLFileSystem
Implementation for delegation by DLFSProvider- Specified by:
newDirectoryStream
in classDLFileSystem
- Returns:
- Directory stream
-
newByteChannel
public SeekableByteChannel newByteChannel(DLPath path, Set<? extends OpenOption> options, FileAttribute<?>[] attrs) throws IOException Description copied from class:DLFileSystem
Implementation for delegation by DLFSProvider- Specified by:
newByteChannel
in classDLFileSystem
- Parameters:
path
- Path for new fileoptions
- Options for file creationattrs
- File attributes- Returns:
- ByteChannel instance
- Throws:
IOException
- In case of IO Error
-
createDirectory
Description copied from class:DLFileSystem
Implementation for delegation by DLFSProvider, create a directory- Specified by:
createDirectory
in classDLFileSystem
- Returns:
- Throws:
IOException
-
createFile
Description copied from class:DLFileSystem
Creates a file, returning the new node- Specified by:
createFile
in classDLFileSystem
- Parameters:
path
- Path for which to create DLFSNode- Returns:
- New file node
- Throws:
IOException
- In event of IOError
-
delete
- Specified by:
delete
in classDLFileSystem
- Throws:
IOException
-
updateNode
Description copied from class:DLFileSystem
Updates a node, returning the new node- Specified by:
updateNode
in classDLFileSystem
- Parameters:
dir
- Path for which to update DLFSNodenewNode
- NEw node to put in place- Returns:
- The new node
-
checkAccess
Description copied from class:DLFileSystem
Implementation for DLFSProvider delegation- Specified by:
checkAccess
in classDLFileSystem
- Parameters:
path
-- Throws:
IOException
-
getRootHash
- Specified by:
getRootHash
in classDLFileSystem
-
merge
Description copied from class:DLFileSystem
Merges another DLFS drive into this one- Specified by:
merge
in classDLFileSystem
- Parameters:
other
- Root node of other DLFS drive
-
clone
- Specified by:
clone
in classDLFileSystem
-