code: function(feature, options) {
          options = options || {};
          var url = options.url ||
                    feature.url ||
                    this.options.url + "/" + feature.fid;
          options = OpenLayers.Util.applyDefaults(options, this.options);
  
          var resp = new OpenLayers.Protocol.Response({
              reqFeatures: feature,
              requestType: "update"
          });
  
          var method = this.updateWithPOST ? "POST" : "PUT";
          resp.priv = OpenLayers.Request[method]({
              url: url,
              callback: this.createCallback(this.handleUpdate, resp, options),
              headers: options.headers,
              data: this.format.write(feature)
          });
  
          return resp;
      }
docs: APIMethod: update
  Construct a request updating modified feature.
  
  Parameters:
  feature - {<OpenLayers.Feature.Vector>}
  options - {Object} Optional object for configuring the request.
  This object is modified and should not be reused.
  
  Returns:
  {<OpenLayers.Protocol.Response>} An <OpenLayers.Protocol.Response>
  object, whose "priv" property references the HTTP request, this
  object is also passed to the callback function when the request
  completes, its "features" property is then populated with the
  the feature received from the server.