9.6 Close the File

When Alice finishes editing the document, after saving her last changes, she exits Word. Since Alice is no longer editing the file, the lock can be released. Before doing this, however, Web Folders does another PROPFIND request to the document itself. The reason for this isn't apparent Web Folders already knows the lock token and has used it in previous requests (see Figure 9-6).

Figure 9-6. Summary of closing a file in Word.

graphics/09fig06.gif

9.6.1 UNLOCK

To release the lock, Web Folders sends a straightforward UNLOCK request. The request must include the correct lock token (see Listing 9-19).

Listing 9-19 UNLOCK request and response.
 UNLOCK /users/alice/work/ergo-accessories.doc HTTP/1.1 Lock-Token: <locktoken:vserver1-LockTokendocstore1:9100> [typical headers omitted] graphics/enter.gif HTTP/1.0 204 No Content Content-Length: 0 Cache-Control: no-cache Pragma: no-cache Date: Sun, 18 Nov 2001 22:33:47 GMT Server: Tomcat Web Server/3.3 Final ( JSP 1.1; Servlet 2.2 ) graphics/enter.gif 

The user has permission to unlock the resource, so the lock is discarded successfully. Now other users or other client software can edit the resource, as long as authentication succeeds.



WebDAV. Next Generation Collaborative Web Authoring
WebDAV. Next Generation Collaborative Web Authoring
ISBN: 130652083
EAN: N/A
Year: 2003
Pages: 146

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net