public class FilePathSplit extends FilePathWrapper
| Constructor and Description |
|---|
FilePathSplit() |
| Modifier and Type | Method and Description |
|---|---|
void |
delete()
Delete a file or directory if it exists.
|
protected String |
getPrefix() |
String |
getScheme()
Get the scheme (prefix) for this file provider.
|
long |
lastModified()
Get the last modified date of a file
|
void |
moveTo(FilePath path)
Rename a file if this is allowed.
|
ArrayList<FilePath> |
newDirectoryStream()
List the files and directories in the given directory.
|
InputStream |
newInputStream()
Create an input stream to read from the file.
|
OutputStream |
newOutputStream(boolean append)
Create an output stream to write into the file.
|
FileChannel |
open(String mode)
Open a random access file object.
|
boolean |
setReadOnly()
Disable the ability to write.
|
long |
size()
Get the size of a file in bytes
|
FilePath |
unwrap(String fileName)
Get the base path for the given wrapped path.
|
canWrite, createDirectory, createFile, createTempFile, exists, getBase, getParent, getPath, isAbsolute, isDirectory, toRealPath, unwrap, wrapget, getName, getNextTempFileNamePart, register, toString, unregisterprotected String getPrefix()
getPrefix in class FilePathWrapperpublic FilePath unwrap(String fileName)
FilePathWrapperunwrap in class FilePathWrapperfileName - the path including the scheme prefixpublic boolean setReadOnly()
FilePathsetReadOnly in class FilePathWrapperpublic void delete()
FilePathdelete in class FilePathWrapperpublic long lastModified()
FilePathlastModified in class FilePathWrapperpublic long size()
FilePathsize in class FilePathWrapperpublic ArrayList<FilePath> newDirectoryStream()
FilePathnewDirectoryStream in class FilePathWrapperpublic InputStream newInputStream() throws IOException
FilePathnewInputStream in class FilePathWrapperIOExceptionpublic FileChannel open(String mode) throws IOException
FilePathopen in class FilePathWrappermode - the access mode. Supported are r, rw, rws, rwdIOExceptionpublic OutputStream newOutputStream(boolean append)
FilePathnewOutputStream in class FilePathWrapperappend - if true, the file will grow, if false, the file will be
truncated firstpublic void moveTo(FilePath path)
FilePathmoveTo in class FilePathWrapperpath - the new fully qualified file nameCopyright © 2012 JBoss by Red Hat. All Rights Reserved.