Class DefaultFileSystem
- java.lang.Object
-
- org.apache.commons.configuration2.io.FileSystem
-
- org.apache.commons.configuration2.io.DefaultFileSystem
-
- Direct Known Subclasses:
VFSFileSystem
public class DefaultFileSystem extends FileSystem
FileSystem that uses java.io.File or HttpClient.- Since:
- 1.7
-
-
Constructor Summary
Constructors Constructor Description DefaultFileSystem()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetBasePath(String path)StringgetFileName(String path)InputStreamgetInputStream(URL url)InputStreamgetInputStream(URL url, URLConnectionOptions urlConnectionOptions)Not abstract for binary compatibility.OutputStreamgetOutputStream(File file)OutputStreamgetOutputStream(URL url)StringgetPath(File file, URL url, String basePath, String fileName)URLgetURL(String basePath, String file)URLlocateFromURL(String basePath, String fileName)-
Methods inherited from class org.apache.commons.configuration2.io.FileSystem
getFileOptionsProvider, getLogger, setFileOptionsProvider, setLogger
-
-
-
-
Constructor Detail
-
DefaultFileSystem
public DefaultFileSystem()
-
-
Method Detail
-
getInputStream
public InputStream getInputStream(URL url) throws ConfigurationException
- Specified by:
getInputStreamin classFileSystem- Throws:
ConfigurationException
-
getInputStream
public InputStream getInputStream(URL url, URLConnectionOptions urlConnectionOptions) throws ConfigurationException
Description copied from class:FileSystemNot abstract for binary compatibility.- Overrides:
getInputStreamin classFileSystem- Parameters:
url- TODOurlConnectionOptions- Ignored.- Returns:
- TODO
- Throws:
ConfigurationException- TODO
-
getOutputStream
public OutputStream getOutputStream(URL url) throws ConfigurationException
- Specified by:
getOutputStreamin classFileSystem- Throws:
ConfigurationException
-
getOutputStream
public OutputStream getOutputStream(File file) throws ConfigurationException
- Specified by:
getOutputStreamin classFileSystem- Throws:
ConfigurationException
-
getPath
public String getPath(File file, URL url, String basePath, String fileName)
- Specified by:
getPathin classFileSystem
-
getBasePath
public String getBasePath(String path)
- Specified by:
getBasePathin classFileSystem
-
getFileName
public String getFileName(String path)
- Specified by:
getFileNamein classFileSystem
-
getURL
public URL getURL(String basePath, String file) throws MalformedURLException
- Specified by:
getURLin classFileSystem- Throws:
MalformedURLException
-
locateFromURL
public URL locateFromURL(String basePath, String fileName)
- Specified by:
locateFromURLin classFileSystem
-
-