public abstract class DavRequest extends Object
Constructor and Description |
---|
DavRequest() |
Modifier and Type | Method and Description |
---|---|
abstract String |
getCharacterEncoding()
Returns request encoding.
|
List<String> |
getClientLockTokens()
Gets the array of lock tokens submitted by client.
|
abstract long |
getContentLength()
Returns the length, in bytes, of the request body.
|
abstract String |
getContentType()
Returns the MIME type of the body of the request, or
null . |
abstract String |
getContextPath()
Returns the portion of the request URI that indicates the context
of the request.
|
abstract String |
getHeader(String name)
Returns http header by name or null if not exists.
|
abstract Enumeration<String> |
getHeaderNames()
Returns an enumeration of all the header names
this request contains.
|
abstract InputStream |
getInputStream()
Retrieves the body of the request as binary data using
a
InputStream . |
abstract String |
getMethod()
Returns http method of the request.
|
abstract Object |
getOriginalRequest()
Returns the original request that was sent by the chosen web container.
|
abstract String |
getQueryString()
Returns the query string that is contained in the request
URL after the path.
|
abstract String |
getRequestURI()
Returns the part of this request's URL from the protocol
name up to the query string in the first line of the HTTP request.
|
abstract String |
getScheme()
Returns http or https server scheme.
|
abstract String |
getServerName()
Returns server name.
|
abstract String |
getServerPath()
Returns the part of this request's URL that calls
the server.
|
abstract int |
getServerPort()
Returns port at which server is running.
|
public abstract String getHeader(String name)
name
- Name of the header.public abstract String getMethod()
public abstract String getRequestURI()
String
containing
the part of the URL from the
protocol name up to the query string.public abstract String getQueryString()
String
containing the query
string or null
if the URL
contains no query string. The value is not
decoded by the container.public abstract String getContextPath()
String
specifying the
portion of the request URI that indicates the context
of the request.public abstract String getServerPath()
String
containing
the name or path of the server being
called, as specified in the request URL,
decoded, or an empty string if the server
used to process the request is matched
using the "/*" pattern.public abstract int getServerPort()
int
port.public abstract String getScheme()
public abstract String getServerName()
public abstract String getCharacterEncoding()
public abstract InputStream getInputStream() throws IOException
InputStream
.InputStream
object containing
the body of the request.IOException
- if an input or output exception occurred.public abstract long getContentLength()
public abstract String getContentType()
null
.String
containing the name
of the MIME type of
the request, or null if the type is not known.public abstract Enumeration<String> getHeaderNames()
public abstract Object getOriginalRequest()
public List<String> getClientLockTokens()
Gets array of lock tokens submitted by client. You must generate the lock tokens during the call to your
Lock.lock(boolean, boolean, long, java.lang.String)
method implementation. During this call you associate generated token with an item in
the repository and return it to the Engine. Engine than sends the new token to the WebDAV client.
When WebDAV client is modifying any server item it sends back to server the list of lock tokens.
In your WebDAV server Class 2 implementation before modifying any locked items you must check if WebDAV
client provided necessary lock token.
Copyright © ITHit. All Rights Reserved.