org.apache.maven.wagon.providers.webdav
Class CorrectedWebdavResource
WebdavResource
org.apache.maven.wagon.providers.webdav.CorrectedWebdavResource
public class CorrectedWebdavResource
extends WebdavResource
Corrected Webdav Resource.
This extension to the WebdavResource object corrects a Content-Length
bug in the WebdavLib.
void | addRequestHeader(String header, String value) - Add a header in the request sent to the webdav server
|
protected void | generateAdditionalHeaders(HttpMethod method) - Add all additionals headers that have been previously registered
with addRequestHeader to the method
|
Map | getHeaders()
|
InputStream | getMethodData(String path) - Get InputStream for the GET method for the given path.
|
boolean | putMethod(String path, InputStream inputStream, int contentLength) - Execute the PUT method for the given path.
|
void | setHeaders(Map headers)
|
CorrectedWebdavResource
public CorrectedWebdavResource(HttpURL url)
throws IOException
addRequestHeader
public void addRequestHeader(String header,
String value)
Add a header in the request sent to the webdav server
header
- Header namevalue
- Value
generateAdditionalHeaders
protected void generateAdditionalHeaders(HttpMethod method)
Add all additionals headers that have been previously registered
with addRequestHeader to the method
getHeaders
public Map getHeaders()
getMethodData
public InputStream getMethodData(String path)
throws IOException
Get InputStream for the GET method for the given path.
path
- the server relative path of the resource to get
putMethod
public boolean putMethod(String path,
InputStream inputStream,
int contentLength)
throws IOException
Execute the PUT method for the given path.
path
- the server relative path to put the datainputStream
- The input stream.
- true if the method is succeeded.
setHeaders
public void setHeaders(Map headers)