Ingo, I've tried the code below but am not able to retrieve anything (blank
output). Version 1.2 has a label set.

    WebdavResource res = new WebdavResource(....
    res.setPath("/slide/files/recipes.txt");
  ---

   PropertyName name = new PropertyName("DAV:", "label-name-set");
  Vector v = new Vector();
  v.add(name);

  Vector hist = new Vector();
  hist.add("/slide/history/1/1.1");
  hist.add("/slide/history/1/1.2");
  hist.add("/slide/history/1/1.3");
  hist.add("/slide/history/1/1.4");

  Enumeration enum = res.reportMethod(res.getHttpURL(), v, hist,
DepthSupport.DEPTH_0);

  while (enum.hasMoreElements())
  {
   ResponseEntity ent = (ResponseEntity)enum.nextElement();
   Enumeration enum1 = ent.getProperties();
   while (enum.hasMoreElements())
   {
    System.out.println(enum1.nextElement().toString());
   }
  }

Could you kindly let me know what I'm doing wrong? Also, is there any
documentation on the return types for most of these methods? A lot of them
seem to return Enumerations with other elements within them (such as
ResponseEntity), but the javadocs are missing.

Thanks!
Karthik

----- Original Message ----- 
From: "Ingo Brunberg" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, June 16, 2004 3:30 AM
Subject: Re: How can I determine what version has a given label


> > kranga wrote:
> > > I've tried using propfind <path> label-name-set and this returns
blank. The
> > > label property holds a set of labels as a revision can have multiple
labels.
> > > How do I query the labels out? Someone please help!
> >
> > You need to do your propfind (for label-name-set) on the version paths.
> > There's no simple/quick way to say 'give me a list of all the labels
> > that are set on any version of this resource' (an argument could
> > certainly be made that this would be a useful thing, though) as far as I
> > know.
>
> No, there is a way of doing this. Just use the REPORT method on your
> version controlled resource and ask for the label-name-set.
>
> >
> > Fetching a particular version with a label set is, of course, much
> > simpler - just set the Label header appropriately.
> >
> > Mike
>
> The Label header is deprecated. I'm not sure if it is supported by
> Slide anyway. You have to find out (from the results of the REPORT
> method) which version has a given label set. Then you request exactly
> that version by a simple GET.
>
> Ingo
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to