+2005-10-06 Helge Hess <helge.hess@opengroupware.org>
+
+ * WebDAV/SoObjectWebDAVDispatcher.m: decode XML content of REPORT
+ requests (v4.5.208)
+
2005-10-05 Helge Hess <helge.hess@opengroupware.org>
* DynamicElements/WOCompoundElement.m: setup defaults in +initialize
/* DAV reports */
- (id)doREPORT:(WOContext *)_ctx {
+ WORequest *rq;
+ id domDocument;
+
+ rq = [_ctx request];
+
+ /* ensure XML */
+
+ if (![[rq headerForKey:@"content-type"] hasPrefix:@"text/xml"]) {
+ return [self httpException:400 /* invalid request */
+ reason:@"XML entity expected for WebDAV REPORT."];
+ }
+
+ /* retrieve XML */
+
+ if ((domDocument = [rq contentAsDOMDocument]) == nil) {
+ return [self httpException:400 /* invalid request */
+ reason:@"Could not parse XML of WebDAV REPORT."];
+ }
+
+ /* process DOM */
+
+ [self logWithFormat:@"TODO: process REPORT: %@", domDocument];
+
return [self httpException:405 /* method not allowed */
reason:@"WebDAV reports not yet implemented."];
}