org.apache.commons.vfs.provider
Interface FileProvider

All Known Subinterfaces:
LocalFileProvider
All Known Implementing Classes:
AbstractFileProvider, AbstractLayeredFileProvider, CompressedFileFileProvider, DefaultLocalFileProvider, RamFileProvider, TarFileProvider, TemporaryFileProvider, ZipFileProvider

public interface FileProvider

A file provider. Each file provider is responsible for handling files for a particular URI scheme.

A file provider may also implement VfsComponent.

Version:
$Revision: 480428 $ $Date: 2006-11-29 07:15:24 +0100 (Mi, 29 Nov 2006) $
Author:
Adam Murdoch

Method Summary
 FileObject createFileSystem(String scheme, FileObject file, FileSystemOptions fileSystemOptions)
          Creates a layered file system.
 FileObject findFile(FileObject baseFile, String uri, FileSystemOptions fileSystemOptions)
          Locates a file object, by absolute URI.
 Collection getCapabilities()
          Get the filesystem capabilities.
 FileSystemConfigBuilder getConfigBuilder()
          Gets the configbuilder useable to collect the needed fileSystemOptions.
 FileName parseUri(FileName root, String uri)
           
 

Method Detail

findFile

public FileObject findFile(FileObject baseFile,
                           String uri,
                           FileSystemOptions fileSystemOptions)
                    throws FileSystemException
Locates a file object, by absolute URI.

Parameters:
baseFile - The base file to use for resolving the individual parts of a compound URI.
uri - The absolute URI of the file to find.
fileSystemOptions -
Throws:
FileSystemException

createFileSystem

public FileObject createFileSystem(String scheme,
                                   FileObject file,
                                   FileSystemOptions fileSystemOptions)
                            throws FileSystemException
Creates a layered file system.

Parameters:
scheme - The URI scheme for the layered file system.
file - The file to build the file system on.
fileSystemOptions -
Throws:
FileSystemException

getConfigBuilder

public FileSystemConfigBuilder getConfigBuilder()
Gets the configbuilder useable to collect the needed fileSystemOptions.


getCapabilities

public Collection getCapabilities()
Get the filesystem capabilities.
These are the same as on the filesystem, but available before the first filesystem was instanciated.


parseUri

public FileName parseUri(FileName root,
                         String uri)
                  throws FileSystemException
Throws:
FileSystemException


Copyright © 2002-2006 The Apache Software Foundation. All Rights Reserved.