Branch: Tag:

2004-05-03

2004-05-03 20:10:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added support for the <DAV:supportedlock/> and <DAV:lockdiscovery/> properties.

Rev: server/etc/modules/PropertySet.pike:1.6

55:    "DAV:supportedlock",    "DAV:iscollection",    "DAV:isfolder", +  "DAV:lockdiscovery", +  "DAV:supportedlock",   >);      private constant all_properties_file = all_properties_common + (<
96:   //! @value "DAV:getlastmodified"   //! RFC2518 13.7   //! + //! @value "DAV:lockdiscovery" + //! RFC2518 13.8 + //!   //! @value "DAV:resourcetype"   //! RFC2518 13.9   //!
287:    case "DAV:getlastmodified": // RFC2518 13.7    return get_response_headers()["Last-Modified"];    +  case "DAV:lockdiscovery": // RFC2518 13.8 +  return indices(id->conf->find_locks(path, 0, 0, id))->get_xml(); +     case "DAV:resourcetype": // RFC2518 13.9    if (get_stat()->isdir) {    return ({
296:    return 0;       case "DAV:supportedlock": // RFC2518 13.11 -  return ""; -  +  { +  array(Parser.XML.Tree.Node) res = ({ +  Parser.XML.Tree.ElementNode("DAV:lockentry", ([])), +  Parser.XML.Tree.ElementNode("DAV:lockentry", ([])), +  }); +  res->add_child(Parser.XML.Tree.ElementNode("DAV:lockscope", ([]))); +  res[0]->get_last_child()-> +  add_child(Parser.XML.Tree.ElementNode("DAV:exclusive", ([]))); +  res[1]->get_last_child()-> +  add_child(Parser.XML.Tree.ElementNode("DAV:exclusive", ([]))); +  res->add_child(Parser.XML.Tree.ElementNode("DAV:locktype", ([])))-> +  add_child(Parser.XML.Tree.ElementNode("DAV:write", ([]))); +  return res; +  }    case "http://apache.org/dav/props/executable":    // http://www.webdav.org/mod_dav/:    //