com.caucho.vfs
Class HttpsPath

java.lang.Object
  extended by com.caucho.vfs.Path
      extended by com.caucho.vfs.FilesystemPath
          extended by com.caucho.vfs.HttpPath
              extended by com.caucho.vfs.HttpsPath
All Implemented Interfaces:
java.lang.Comparable<Path>

public class HttpsPath
extends HttpPath

The HTTP scheme. Currently it supports GET and POST.

TODO: support WEBDAV, enabling the full Path API.


Field Summary
protected static L10N L
           
 
Fields inherited from class com.caucho.vfs.HttpPath
_cache, _cacheEntry, _host, _port, _query, _virtualHost
 
Fields inherited from class com.caucho.vfs.FilesystemPath
_bindRoot, _pathname, _root, _userPath
 
Fields inherited from class com.caucho.vfs.Path
_pathSeparatorChar, _schemeMap, _separatorChar
 
Constructor Summary
HttpsPath(FilesystemPath root, java.lang.String userPath, java.util.Map<java.lang.String,java.lang.Object> newAttributes, java.lang.String path, java.lang.String query)
          Creates a new HTTP sub path.
HttpsPath(java.lang.String host, int port)
          Creates a new HTTP root path with a host and a port.
 
Method Summary
protected  HttpPath create(FilesystemPath root, java.lang.String userPath, java.util.Map<java.lang.String,java.lang.Object> newAttributes, java.lang.String path, java.lang.String query)
           
protected  HttpPath create(java.lang.String host, int port)
           
 boolean equals(java.lang.Object o)
          Overrides equals to test for equality with an HTTP path.
 java.lang.String getScheme()
          Returns the scheme, http.
 int hashCode()
          Returns a hashCode for the path.
 StreamImpl openReadImpl()
          Returns a read stream for a GET request.
 StreamImpl openReadWriteImpl()
          Returns a read/write pair for a POST request.
 
Methods inherited from class com.caucho.vfs.HttpPath
cacheCopy, canRead, exists, fsWalk, getCache, getHost, getLastModified, getLength, getPort, getQuery, getURL, getUserPath, getVirtualHost, isDirectory, isFile, lookupImpl, schemeWalk, toString
 
Methods inherited from class com.caucho.vfs.FilesystemPath
bind, createRoot, getFullPath, getParent, getPath, getRoot, getTail, normalizePath, normalizePath, setUserPath
 
Methods inherited from class com.caucho.vfs.Path
canExecute, canWrite, changeGroup, changeGroup, changeOwner, changeOwner, chmod, clearStatusCache, compareTo, copy, createDepend, createLink, createNewFile, createRoot, createTempFile, escapeURL, getAttribute, getAttributeNames, getBlockCount, getBlockSize, getCache, getCertificates, getContentType, getCrc64, getCreateTime, getDevice, getDeviceId, getDiskSpaceFree, getDiskSpaceTotal, getFileSeparatorChar, getGroup, getInode, getLastAccessTime, getLastStatusChangeTime, getMode, getNativePath, getNewlineString, getNumberOfLinks, getObject, getOwner, getPathSeparatorChar, getRelativePath, getResources, getResources, getSchemeMap, getSeparatorChar, getUser, getUserDir, getValue, isBlockDevice, isCharacterDevice, isExecutable, isFIFO, isHardLink, isLink, isObject, isPathCacheable, isSocket, isSymbolicLink, isWindows, isWindowsInsecure, iterator, list, lookup, lookup, lookup, lookupNative, lookupNative, lookupRelativeNativePath, mkdir, mkdirs, openAppend, openAppendImpl, openFileRandomAccess, openMemoryMappedFile, openRandomAccess, openRead, openReadWrite, openReadWrite, openReadWrite, openWrite, openWriteImpl, putCache, readLink, realPath, remove, removeAll, renameTo, renameTo, scanScheme, setDefaultSchemeMap, setExecutable, setLastModified, setObject, setTestWindows, setValue, truncate, truncate, unbind, writeToStream, writeToStream
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

L

protected static L10N L
Constructor Detail

HttpsPath

public HttpsPath(java.lang.String host,
                 int port)
Creates a new HTTP root path with a host and a port.

Parameters:
host - the target host
port - the target port, if zero, uses port 80.

HttpsPath

public HttpsPath(FilesystemPath root,
                 java.lang.String userPath,
                 java.util.Map<java.lang.String,java.lang.Object> newAttributes,
                 java.lang.String path,
                 java.lang.String query)
Creates a new HTTP sub path.

Parameters:
root - the HTTP filesystem root
userPath - the argument to the calling lookup()
newAttributes - any attributes passed to http
path - the full normalized path
query - any query string
Method Detail

create

protected HttpPath create(java.lang.String host,
                          int port)
Overrides:
create in class HttpPath

create

protected HttpPath create(FilesystemPath root,
                          java.lang.String userPath,
                          java.util.Map<java.lang.String,java.lang.Object> newAttributes,
                          java.lang.String path,
                          java.lang.String query)
Overrides:
create in class HttpPath

getScheme

public java.lang.String getScheme()
Returns the scheme, http.

Overrides:
getScheme in class HttpPath

openReadImpl

public StreamImpl openReadImpl()
                        throws java.io.IOException
Returns a read stream for a GET request.

Overrides:
openReadImpl in class HttpPath
Throws:
java.io.IOException

openReadWriteImpl

public StreamImpl openReadWriteImpl()
                             throws java.io.IOException
Returns a read/write pair for a POST request.

Overrides:
openReadWriteImpl in class HttpPath
Throws:
java.io.IOException

hashCode

public int hashCode()
Returns a hashCode for the path.

Overrides:
hashCode in class HttpPath

equals

public boolean equals(java.lang.Object o)
Overrides equals to test for equality with an HTTP path.

Overrides:
equals in class HttpPath