org.apache.jackrabbit.webdav.client.methods
Interface DavMethod

All Superinterfaces:
org.apache.commons.httpclient.HttpMethod
All Known Implementing Classes:
AclMethod, BaselineControlMethod, BindMethod, CheckinMethod, CheckoutMethod, CopyMethod, DavMethodBase, DeleteMethod, LabelMethod, LockMethod, MergeMethod, MkActivityMethod, MkColMethod, MkWorkspaceMethod, MoveMethod, OptionsMethod, OrderPatchMethod, PollMethod, PropFindMethod, PropPatchMethod, PutMethod, RebindMethod, ReportMethod, SearchMethod, SubscribeMethod, UnbindMethod, UncheckoutMethod, UnLockMethod, UnSubscribeMethod, UpdateMethod, VersionControlMethod

public interface DavMethod
extends org.apache.commons.httpclient.HttpMethod

DavMethod...


Method Summary
 void addRequestHeader(Header header)
          Adds the specified request header, NOT overwriting any previous value.
 void checkSuccess()
           
 Document getResponseBodyAsDocument()
          Parse the response body into an Xml Document.
 MultiStatus getResponseBodyAsMultiStatus()
          Return the response body as MultiStatus object.
 DavException getResponseException()
          Builds a DavException for the status line and the DAV:error element that may be present in the response body.
 void setRequestHeader(Header header)
          Set the specified request header, overwriting any previous value.
 boolean succeeded()
           
 
Methods inherited from interface org.apache.commons.httpclient.HttpMethod
abort, addRequestHeader, addRequestHeader, addResponseFooter, execute, getDoAuthentication, getFollowRedirects, getHostAuthState, getHostConfiguration, getName, getParams, getPath, getProxyAuthState, getQueryString, getRequestHeader, getRequestHeaders, getRequestHeaders, getResponseBody, getResponseBodyAsStream, getResponseBodyAsString, getResponseFooter, getResponseFooters, getResponseHeader, getResponseHeaders, getResponseHeaders, getStatusCode, getStatusLine, getStatusText, getURI, hasBeenUsed, isRequestSent, isStrictMode, recycle, releaseConnection, removeRequestHeader, removeRequestHeader, setDoAuthentication, setFollowRedirects, setParams, setPath, setQueryString, setQueryString, setRequestHeader, setRequestHeader, setStrictMode, setURI, validate
 

Method Detail

addRequestHeader

void addRequestHeader(Header header)
Adds the specified request header, NOT overwriting any previous value. Note that header-name matching is case insensitive.

Parameters:
header -
See Also:
HttpMethod.addRequestHeader(String, String)

setRequestHeader

void setRequestHeader(Header header)
Set the specified request header, overwriting any previous value. Note that header-name matching is case-insensitive.

Parameters:
header -
See Also:
HttpMethod.setRequestHeader(String, String)

getResponseBodyAsDocument

Document getResponseBodyAsDocument()
                                   throws IOException
Parse the response body into an Xml Document.

Returns:
Xml document or null if the response stream is null.
Throws:
IOException - If an I/O (transport) problem occurs while obtaining the response body of if the XML parsing fails.
See Also:
HttpMethod.getResponseBody(), HttpMethod.getResponseBodyAsStream(), HttpMethod.getResponseBodyAsString()

getResponseBodyAsMultiStatus

MultiStatus getResponseBodyAsMultiStatus()
                                         throws IOException,
                                                DavException
Return the response body as MultiStatus object.

Returns:
Throws:
IOException - if the response body could not be parsed
DavException - if the status code is other than MultiStatus or if obtaining the response XML document fails
See Also:
getResponseBodyAsDocument()

getResponseException

DavException getResponseException()
                                  throws IOException
Builds a DavException for the status line and the DAV:error element that may be present in the response body. If the response does not indicate an error, null will be returned.

Returns:
DavException or null if this method did not result in an error.
Throws:
IOException

checkSuccess

void checkSuccess()
                  throws DavException,
                         IOException
Throws:
DavException
IOException

succeeded

boolean succeeded()
Returns:
true if the method was successfully executed


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.