org.restlet.ext.wadl
Class LinkInfo

java.lang.Object
  extended by org.restlet.ext.wadl.DocumentedInfo
      extended by org.restlet.ext.wadl.LinkInfo

public class LinkInfo
extends DocumentedInfo

Allows description of links between representations and resources.

Author:
Jerome Louvel

Constructor Summary
LinkInfo()
          Constructor.
LinkInfo(DocumentationInfo documentation)
          Constructor with a single documentation element.
LinkInfo(java.util.List<DocumentationInfo> documentations)
          Constructor with a list of documentation elements.
LinkInfo(java.lang.String documentation)
          Constructor with a single documentation element.
 
Method Summary
 java.lang.String getRelationship()
          Returns the relationship attribute value.
 Reference getResourceType()
          Returns the reference to the resource type of the linked resource.
 java.lang.String getReverseRelationship()
          Returns the reverse relationship attribute value.
 void setRelationship(java.lang.String relationship)
          Sets the relationship attribute value.
 void setResourceType(Reference resourceType)
          Sets the reference to the resource type of the linked resource.
 void setReverseRelationship(java.lang.String reverseRelationship)
          Sets the reverse relationship attribute value.
 void updateNamespaces(java.util.Map<java.lang.String,java.lang.String> namespaces)
          Completes the given map of namespaces with the namespaces used in the documentation elements.
 void writeElement(XmlWriter writer)
          Writes the current object as an XML element using the given SAX writer.
 
Methods inherited from class org.restlet.ext.wadl.DocumentedInfo
getDocumentations, resolveNamespaces, setDocumentation, setDocumentation, setDocumentations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinkInfo

public LinkInfo()
Constructor.


LinkInfo

public LinkInfo(DocumentationInfo documentation)
Constructor with a single documentation element.

Parameters:
documentation - A single documentation element.

LinkInfo

public LinkInfo(java.util.List<DocumentationInfo> documentations)
Constructor with a list of documentation elements.

Parameters:
documentations - The list of documentation elements.

LinkInfo

public LinkInfo(java.lang.String documentation)
Constructor with a single documentation element.

Parameters:
documentation - A single documentation element.
Method Detail

getRelationship

public java.lang.String getRelationship()
Returns the relationship attribute value.

Returns:
The relationship attribute value.

getResourceType

public Reference getResourceType()
Returns the reference to the resource type of the linked resource.

Returns:
The reference to the resource type of the linked resource.

getReverseRelationship

public java.lang.String getReverseRelationship()
Returns the reverse relationship attribute value.

Returns:
The reverse relationship attribute value.

setRelationship

public void setRelationship(java.lang.String relationship)
Sets the relationship attribute value.

Parameters:
relationship - The relationship attribute value.

setResourceType

public void setResourceType(Reference resourceType)
Sets the reference to the resource type of the linked resource.

Parameters:
resourceType - The reference to the resource type of the linked resource.

setReverseRelationship

public void setReverseRelationship(java.lang.String reverseRelationship)
Sets the reverse relationship attribute value.

Parameters:
reverseRelationship - The reverse relationship attribute value.

updateNamespaces

public void updateNamespaces(java.util.Map<java.lang.String,java.lang.String> namespaces)
Description copied from class: DocumentedInfo
Completes the given map of namespaces with the namespaces used in the documentation elements. The key is the URI of the namespace and the value, the prefix.

Specified by:
updateNamespaces in class DocumentedInfo
Parameters:
namespaces - The given map of namespaces to complete.

writeElement

public void writeElement(XmlWriter writer)
                  throws org.xml.sax.SAXException
Writes the current object as an XML element using the given SAX writer.

Parameters:
writer - The SAX writer.
Throws:
org.xml.sax.SAXException


Copyright © 2005-2008 Noelios Technologies.