public static interface WebApplication.LocalFile
Modifier and Type | Method and Description |
---|---|
void |
delete() |
boolean |
exists() |
String |
getFullPath() |
InputStream |
getInputStream() |
long |
getLength() |
long |
getMaxLength() |
String |
getName() |
OutputStream |
getOutputStream(boolean append,
long minLength,
long maxLength) |
WebApplication.LocalDirectory |
getParent() |
RandomStream |
getRandomStream(String mode,
long minLength,
long maxLength)
Open the file for
|
int |
getTag() |
URL |
getURL() |
boolean |
isValid() |
long |
setMaxLength(long maxLength) |
void |
setTag(int tag) |
WebApplication.LocalDirectory getParent()
String getName()
String getFullPath()
boolean isValid()
boolean exists()
long getMaxLength() throws IOException
IOException
long setMaxLength(long maxLength) throws IOException
IOException
long getLength() throws IOException
IOException
void delete() throws IOException
IOException
InputStream getInputStream() throws IOException
IOException
OutputStream getOutputStream(boolean append, long minLength, long maxLength) throws WebApplication.FileSizeNotAllowedException, IOException
RandomStream getRandomStream(String mode, long minLength, long maxLength) throws WebApplication.FileSizeNotAllowedException, IOException
mode
- the mode for opening. This should be "r" or "rw".minLength
- only used for "rw" - it will ensure that the max length of the file is at least of this length. If it is 0 or
negative it will be ignored if the file already exists. If the file does not exist and this number is greater than zero then
the file is created and must have at least this length allocated as its maximum length, otherwise a FileSizeNotAllowedException is thrown.maxLength
- only used for "rw" - it specifies a suggested, but not required, maximum length for the file during creation but not when the file already
exists. If it is 0 or negative it will be ignored.IOException
WebApplication.FileSizeNotAllowedException
int getTag() throws IOException
IOException
void setTag(int tag) throws IOException
IOException
URL getURL()