Class UpdateMethod

  • All Implemented Interfaces:
    org.apache.commons.httpclient.HttpMethod

    public class UpdateMethod
    extends XMLResponseMethodBase
    The Update method updates a version-controlled resource to a new version. Two parameters are required, the path of the resource, and a URI identifying the version from the history to which to update.
    • Constructor Detail

      • UpdateMethod

        public UpdateMethod()
        Method constructor.
      • UpdateMethod

        public UpdateMethod​(java.lang.String path)
        Method constructor.
      • UpdateMethod

        public UpdateMethod​(java.lang.String path,
                            java.lang.String target)
        Method constructor.
        Parameters:
        path -
        target -
    • Method Detail

      • getName

        public java.lang.String getName()
        Specified by:
        getName in interface org.apache.commons.httpclient.HttpMethod
        Specified by:
        getName in class org.apache.commons.httpclient.HttpMethodBase
      • generateRequestBody

        protected java.lang.String generateRequestBody()
        DAV requests that contain a body must override this function to generate that body.

        The default behavior simply returns an empty body.

        Overrides:
        generateRequestBody in class XMLResponseMethodBase
      • parseResponse

        public void parseResponse​(java.io.InputStream input,
                                  org.apache.commons.httpclient.HttpState state,
                                  org.apache.commons.httpclient.HttpConnection conn)
                           throws java.io.IOException,
                                  org.apache.commons.httpclient.HttpException
        Parse response.
        Overrides:
        parseResponse in class XMLResponseMethodBase
        Parameters:
        input - Input stream
        Throws:
        java.io.IOException
        org.apache.commons.httpclient.HttpException