|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.rad.io.DirectoryHandle
public class DirectoryHandle
The DirectorHandle is an IFileHandle representation for directories.
It does not allow file access. It is only an informative class.
| Constructor Summary | |
|---|---|
DirectoryHandle(File pDirectory)
Creates a new instance of DirectoryHandle and checks if the
directory exists. |
|
DirectoryHandle(String pDirectory)
Creates a new instance of DirectoryHandle without checks. |
|
| Method Summary | |
|---|---|
String |
getFileName()
Gets the file name of this file handle. |
InputStream |
getInputStream()
Gets the InputStream of this file handle. |
long |
getLength()
Gets the length of the InputStream in bytes |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DirectoryHandle(String pDirectory)
DirectoryHandle without checks.
pDirectory - the absolute directory path. If the path does not exist,
it doesn't matterpublic DirectoryHandle(File pDirectory)
DirectoryHandle and checks if the
directory exists.
pDirectory - the directory
IllegalArgumentException - if directory does not exist| Method Detail |
|---|
public String getFileName()
getFileName in interface IFileHandle
public InputStream getInputStream()
throws IOException
getInputStream in interface IFileHandleIOException - if an exception occurs.
public long getLength()
throws IOException
getLength in interface IFileHandleIOException - if an exception occurs.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||