be.re.webdav
Class Relations

java.lang.Object
  extended by be.re.webdav.Relations

public class Relations
extends Object

Relations are a Pincette-specific concept. It provides a way to create several named relations between resources. It is a general purpose linking mechanism which is independent of document formats.

Author:
Werner Donné

Nested Class Summary
static class Relations.Relation
           
 
Constructor Summary
Relations()
           
 
Method Summary
static Relations.Relation[] getReferredBy(URL url, Client client)
          This returns the contents of the protected property referred-by in the namespace urn:be-re:dav.
static Relations.Relation[] getReferredByVersions(URL url, Client client)
          This returns the contents of the protected property referred-by-versions in the namespace urn:be-re:dav.
static Relations.Relation[] getReferringTo(URL url, Client client)
          This returns the contents of the property referring-to in the namespace urn:be-re:dav.
static void setReferringTo(URL url, Client client, Relations.Relation[] relations)
          This sets the property referring-to in the namespace urn:be-re:dav.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Relations

public Relations()
Method Detail

getReferredBy

public static Relations.Relation[] getReferredBy(URL url,
                                                 Client client)
                                          throws IOException,
                                                 be.re.net.ProtocolException
This returns the contents of the protected property referred-by in the namespace urn:be-re:dav. The returned URIs denote the resources that refer to the resource denoted by url. Duplicate relations will not be returned.

Throws:
IOException
be.re.net.ProtocolException

getReferredByVersions

public static Relations.Relation[] getReferredByVersions(URL url,
                                                         Client client)
                                                  throws IOException,
                                                         be.re.net.ProtocolException
This returns the contents of the protected property referred-by-versions in the namespace urn:be-re:dav. The returned URIs denote the resource versions that refer to the resource denoted by url. In Pincette only resource versions can refer to other resources. The returned URIs will be version URIs. Duplicate relations will not be returned.

Throws:
IOException
be.re.net.ProtocolException

getReferringTo

public static Relations.Relation[] getReferringTo(URL url,
                                                  Client client)
                                           throws IOException,
                                                  be.re.net.ProtocolException
This returns the contents of the property referring-to in the namespace urn:be-re:dav. The returned URIs are the ones the resource denoted by url is referring to. Duplicate relations will not be returned.

Throws:
IOException
be.re.net.ProtocolException

setReferringTo

public static void setReferringTo(URL url,
                                  Client client,
                                  Relations.Relation[] relations)
                           throws IOException,
                                  be.re.net.ProtocolException
This sets the property referring-to in the namespace urn:be-re:dav. The given URIs should exist. Duplicate relations will not be stored.

Throws:
IOException
be.re.net.ProtocolException