|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IOProvider
The IOProvider
is an interface to provide more control of
sending output from JSP Java and Class generation phases as well as cleaning
up in case of problems.
Method Summary | |
---|---|
boolean |
delete(java.lang.String fileName)
Remove a generated output. |
java.lang.ClassLoader |
getClassLoader()
Return the class loader to use |
java.io.InputStream |
getInputStream(java.lang.String fileName)
Returns an input stream to a file which has been written through a stream obtained form getOutputStream(String) |
java.io.OutputStream |
getOutputStream(java.lang.String fileName)
|
long |
lastModified(java.lang.String fileName)
Returns the last modification time stamp of the resource (generally a file) at the given absolute location. |
boolean |
mkdirs(java.lang.String path)
Creates folders (folder like) structures, such that a container for data is available at the given path. |
boolean |
rename(java.lang.String oldFileName,
java.lang.String newFileName)
Renames the the file from the old file to the new file name |
Method Detail |
---|
java.io.OutputStream getOutputStream(java.lang.String fileName) throws java.io.IOException
fileName
- The absolute path name of the destination into which to
write the output. The semantics of this path depends on the
implementation of this interface.
OutputStream
into which to write the generated
output.
java.io.IOException
- If the output stream cannot be created for the file.java.io.InputStream getInputStream(java.lang.String fileName) throws java.io.FileNotFoundException, java.io.IOException
getOutputStream(String)
fileName
- The absolute path name of the source from which to
read the input. The semantics of this path depends on the
implementation of this interface.
InputStream
from which to read the input.
java.io.FileNotFoundException
- If the file cannot be found
java.io.IOException
- If any other error occurs.boolean delete(java.lang.String fileName)
fileName
- The absolute path name of the item to remove. The
semantics of this path depends on the implementation of this
interface.
true
if the item could be removed, otherwise
false
is removed.boolean rename(java.lang.String oldFileName, java.lang.String newFileName)
oldFileName
- newFileName
-
true
if renaming succeededboolean mkdirs(java.lang.String path)
In the case of a OS Filesystem implementation, this method would be
implemented by means of new java.io.File(path).mkdirs()
.
path
- The absolute path of the folder to create.
true
if and only if the folder was created, along
with all necessary parent directories; false
otherwise.long lastModified(java.lang.String fileName)
fileName
- The absolute path to the file whose last modification
time stamp is to be returned.
java.lang.ClassLoader getClassLoader()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |