public abstract class AbstractOriginatingFileProvider extends AbstractFileProvider
FileProvider
that handles physical files, such as the files in a local fs, or on an FTP server. An
originating file system cannot be layered on top of another file system.Constructor and Description |
---|
AbstractOriginatingFileProvider() |
Modifier and Type | Method and Description |
---|---|
protected abstract FileSystem |
doCreateFileSystem(FileName rootFileName,
FileSystemOptions fileSystemOptions)
Creates a
FileSystem . |
protected FileObject |
findFile(FileName fileName,
FileSystemOptions fileSystemOptions)
Locates a file from its parsed URI.
|
FileObject |
findFile(FileObject baseFileObject,
String uri,
FileSystemOptions fileSystemOptions)
Locates a file object, by absolute URI.
|
protected FileSystem |
getFileSystem(FileName rootFileName,
FileSystemOptions fileSystemOptions)
Returns the FileSystem associated with the specified root.
|
addFileSystem, close, closeFileSystem, createFileSystem, findFileSystem, freeUnusedResources, getConfigBuilder, getFileNameParser, parseUri, setFileNameParser
addComponent, removeComponent
getContext, getLogger, init, setContext, setLogger
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getCapabilities
public FileObject findFile(FileObject baseFileObject, String uri, FileSystemOptions fileSystemOptions) throws FileSystemException
baseFileObject
- The base file object.uri
- The URI of the file to locatefileSystemOptions
- The FileSystem options.FileSystemException
- if an error occurs.protected FileObject findFile(FileName fileName, FileSystemOptions fileSystemOptions) throws FileSystemException
fileName
- The file name.fileSystemOptions
- FileSystem options.FileSystemException
- if an error occurs.protected FileSystem getFileSystem(FileName rootFileName, FileSystemOptions fileSystemOptions) throws FileSystemException
rootFileName
- The root path.fileSystemOptions
- The FileSystem options.FileSystemException
- if an error occurs.protected abstract FileSystem doCreateFileSystem(FileName rootFileName, FileSystemOptions fileSystemOptions) throws FileSystemException
FileSystem
. If the returned FileSystem implements VfsComponent
, it will be initialized.rootFileName
- The name of the root file of the file system to create.fileSystemOptions
- The FileSystem options.FileSystemException
- if an error occurs.Copyright © 2002–2020 The Apache Software Foundation. All rights reserved.