|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.caucho.vfs.Path | +--com.caucho.vfs.FilesystemPath | +--com.caucho.vfs.HttpPath
The HTTP scheme. Currently it supports GET and POST.
TODO: support WEBDAV, enabling the full Path API.
Field Summary | |
protected java.lang.String |
host
|
protected int |
port
|
protected java.lang.String |
query
|
Fields inherited from class com.caucho.vfs.FilesystemPath |
bindRoot,
pathname,
root,
separatorChar,
userPath |
Fields inherited from class com.caucho.vfs.Path |
schemeMap |
Method Summary | |
protected Path |
fsWalk(java.lang.String userPath,
java.util.Map attributes,
java.lang.String uri)
Lookup a path relative to the current filesystem's root. |
java.lang.String |
getHost()
Returns the hostname |
int |
getPort()
Returns the port. |
java.lang.String |
getQuery()
Returns the query string of the path. |
java.lang.String |
getScheme()
Returns the url scheme |
java.lang.String |
getURL()
Returns the full url for the given path. |
java.lang.String |
getUserPath()
Returns the last string used as a lookup, if available. |
int |
hashCode()
|
Path |
lookup(java.lang.String userPath,
java.util.Map newAttributes)
Returns a new path relative to the current one. |
StreamImpl |
openReadImpl()
|
StreamImpl |
openReadWriteImpl()
|
protected Path |
schemeWalk(java.lang.String userPath,
java.util.Map attributes,
java.lang.String uri,
int offset)
schemeWalk is called by Path for a scheme lookup like file:/tmp/foo |
java.lang.String |
toString()
|
Methods inherited from class com.caucho.vfs.FilesystemPath |
bind,
copy,
createRoot,
equals,
getFullPath,
getParent,
getPath,
getTail,
normalizePath,
normalizePath,
setUserPath |
Methods inherited from class com.caucho.vfs.Path |
canRead,
canWrite,
createNewFile,
createTempFile,
exists,
getAttribute,
getAttributeNames,
getContentType,
getLastModified,
getLength,
getNativePath,
getValue,
isDirectory,
isFile,
isObject,
iterator,
list,
lookup,
lookupNative,
lookupNative,
mkdir,
mkdirs,
openAppend,
openAppendImpl,
openRead,
openReadWrite,
openWrite,
openWriteImpl,
remove,
removeAttribute,
renameTo,
renameTo,
scanScheme,
setAttribute,
setLastModified,
setValue,
unbind,
writeToStream |
Methods inherited from class java.lang.Object |
clone,
finalize,
getClass,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
protected java.lang.String host
protected int port
protected java.lang.String query
Method Detail |
public Path lookup(java.lang.String userPath, java.util.Map newAttributes)
Path only handles scheme:xxx. Subclasses of Path will specialize the xxx.
userPath
- relative or absolute path, essentially any url.newAttributes
- attributes for the new path.protected Path schemeWalk(java.lang.String userPath, java.util.Map attributes, java.lang.String uri, int offset)
userPath
- the user's lookup() pathattributes
- the user's attributesfilePath
- the actual lookup() pathoffset
- offset into filePathprotected Path fsWalk(java.lang.String userPath, java.util.Map attributes, java.lang.String uri)
userPath
- the exact string passed by the user's lookup()newAttributes
- the user's new attributesnewPath
- the normalized real pathpublic java.lang.String getScheme()
public java.lang.String getURL()
public java.lang.String getHost()
public int getPort()
public java.lang.String getUserPath()
Path path = Pwd.lookup("/some/dir").lookup("../test.html");
System.out.println(path.getUserPath());
public java.lang.String getQuery()
public StreamImpl openReadImpl() throws java.io.IOException
public StreamImpl openReadWriteImpl() throws java.io.IOException
public java.lang.String toString()
public int hashCode()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |