Re: Achieved Custom Property to Slide Content
Julian Reschke <[email protected]> Mon, 07 May 2007 08:47:17 +0200
| Newsgroups | gmane.comp.jakarta.slide.user |
|---|---|
| Message-ID | <[email protected]> |
Satish wrote:
> Hi Zeus,
>
> Here I came with good news, I am able to create, set and "GET" custom
> properties on Slide resource!
> Thanks a ton for your help!
>
> Zeus one more thing I wanted to implement is ACL using slide, I tried ACE
> and Priviliges stuff but could not able to set them well, may need to dig
> more!
> In case you have or know, can you send me any code which might be doing this
> or may be your valuable suggestions which may help make this happen for me!
>
>
> Here is the code, may also help some one else looking for same!
>
> ------------------------------------------------------------------
> HttpURL hrl = new
> HttpURL("http://ashish:8080/slide/files/FinalXML/Tripsketch.css");
>
> hrl.setUserinfo("root","root");
>
> WebdavResource wdr = new WebdavResource(hrl);
>
> wdr.setDebug(1);
>
> Hashtable props = new Hashtable();
>
> PropertyName prop = new PropertyName("DAV:", "CustomProperty");
>
> props.put(prop, "NewValue");
>
> System.out.println("Execute PropPatchMethodTest...");
>
> System.out.println("returned value ... " + wdr.proppatchMethod(props,
> true));
>
> Enumeration e= wdr.propfindMethod("CustomProperty");
>
> System.out.println("read as ... " + e.nextElement());
>
> ----------------------------------------------------------------------------
> ------------------------
> ..
Note: please do not put custom properties into the "DAV:" namespace.
Best regards, Julian