|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.sourceforge.ganttproject.document.AbstractDocument | +--net.sourceforge.ganttproject.document.URLDocument
This class implements the interface Document for file access on HTTP-servers and WebDAV-enabled-servers.
Constructor Summary | |
URLDocument(java.lang.String url,
java.lang.String user,
java.lang.String pass)
|
Method Summary | |
boolean |
acquireLock()
Tries to acquire a lock. |
boolean |
canRead()
Checks, wether the document is readable. |
boolean |
canWrite()
Checks, wether the document is writable. |
java.lang.String |
getDescription()
Gets the description of the document (can be displayed in the application's titlebar). |
java.io.InputStream |
getInputStream()
Gets an InputStream, that allows to read from the document. |
java.lang.String |
getLastError()
Gets the last error |
java.io.OutputStream |
getOutputStream()
Gets an OutputStream, that allows to write to the document. |
java.lang.String |
getPassword()
Gets the password used to authenticate to the storage container |
java.lang.String |
getPath()
Gets the path to the document. |
java.lang.String |
getURLPath()
Gets the path to the document, if it is a file on a server (can be used to initialize an UrlChooser). |
java.lang.String |
getUsername()
Gets the username used to authenticate to the storage container |
boolean |
isValidForMRU()
Checks, wether the document should appear in the MRU (list of most recently used files). |
void |
releaseLock()
Releases a previously acquired lock. |
void |
setUserInfo(java.lang.String user,
java.lang.String pass)
|
Methods inherited from class net.sourceforge.ganttproject.document.AbstractDocument |
equals, getFilePath |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public URLDocument(java.lang.String url, java.lang.String user, java.lang.String pass)
Method Detail |
public java.lang.String getDescription()
Document
public boolean canRead()
Document
public boolean canWrite()
Document
public boolean isValidForMRU()
Document
public boolean acquireLock()
Document
acquireLock
in interface Document
acquireLock
in class AbstractDocument
Document.releaseLock()
public void releaseLock()
Document
releaseLock
in interface Document
releaseLock
in class AbstractDocument
#acquireLock(String)
public java.io.InputStream getInputStream() throws java.io.IOException
Document
java.io.IOException
public java.io.OutputStream getOutputStream() throws java.io.IOException
Document
java.io.IOException
public java.lang.String getPath()
Document
public java.lang.String getURLPath()
Document
getURLPath
in interface Document
getURLPath
in class AbstractDocument
null
, otherwise.public java.lang.String getUsername()
Document
getUsername
in interface Document
getUsername
in class AbstractDocument
public java.lang.String getPassword()
Document
getPassword
in interface Document
getPassword
in class AbstractDocument
public void setUserInfo(java.lang.String user, java.lang.String pass)
public java.lang.String getLastError()
Document
getLastError
in interface Document
getLastError
in class AbstractDocument
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |