|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Resource
Method Summary | |
---|---|
boolean |
close()
Closes this resource. |
HypertextAccessFile |
getHypertextAccessFile()
Get the resource's hypertext access file settings. |
java.io.InputStream |
getInputStream()
Get the input stream from this resource. |
long |
getLength()
This method returns the *actual* length of the underlying resource. |
ResourceMetaData |
getMetaData()
Get the meta data for this resource. |
java.io.OutputStream |
getOutputStream()
Get the output stream to this resource. |
java.util.concurrent.locks.ReentrantReadWriteLock.ReadLock |
getReadLock()
This method returns the read lock for this resource. |
java.util.concurrent.locks.ReentrantReadWriteLock.WriteLock |
getWriteLock()
This method returns the write lock for this resource. |
boolean |
isOpen()
This method determines if this resource was alerady opened or not. |
boolean |
isReadOnly()
This method returns true if the underlying resource is read-only (in general). |
void |
open(boolean readOnly)
This method opens the underlying resource. |
Method Detail |
---|
ResourceMetaData getMetaData()
HypertextAccessFile getHypertextAccessFile()
java.util.concurrent.locks.ReentrantReadWriteLock.ReadLock getReadLock()
java.util.concurrent.locks.ReentrantReadWriteLock.WriteLock getWriteLock()
void open(boolean readOnly) throws java.io.IOException
readOnly
- if set to true, the resource will be opned in read-only mode.
ReadOnlyException
- If the underlying resource is read-only in general.
java.io.IOException
- If any other IO error occurs.isReadOnly()
boolean isOpen() throws java.io.IOException
java.io.IOException
- If any IO error occurs.boolean isReadOnly() throws java.io.IOException
java.io.IOException
- If any IO error occurs.long getLength() throws java.io.IOException
java.io.IOException
- If any IO error occurs.java.io.OutputStream getOutputStream() throws ReadOnlyException, java.io.IOException
ReadOnlyException
- If this resource was opened with the read-only flag set.
java.io.IOException
- If any other IO error occurs.java.io.InputStream getInputStream() throws java.io.IOException
java.io.IOException
- If any IO error occurs.boolean close() throws java.io.IOException
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |