org.restlet.ext.wadl
Class ApplicationInfo

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

public class ApplicationInfo
extends DocumentedInfo

Root of a WADL description document.

Author:
Jerome Louvel

Constructor Summary
ApplicationInfo()
          Constructor.
ApplicationInfo(DocumentationInfo documentation)
          Constructor with a single documentation element.
ApplicationInfo(java.util.List<DocumentationInfo> documentations)
          Constructor with a list of documentation elements.
ApplicationInfo(java.lang.String documentation)
          Constructor with a single documentation element.
 
Method Summary
 java.util.List<FaultInfo> getFaults()
          Returns the list of fault elements.
 GrammarsInfo getGrammars()
          Returns the grammar elements.
 java.util.List<MethodInfo> getMethods()
          Returns the list of method elements.
 java.util.Map<java.lang.String,java.lang.String> getNamespaces()
          Returns the map of namespaces used in the WADL document.
 java.util.List<RepresentationInfo> getRepresentations()
          Returns the list of representation elements.
 ResourcesInfo getResources()
          Returns the resources root element.
 java.util.List<ResourceTypeInfo> getResourceTypes()
          Returns the list of resource type elements.
 void setFaults(java.util.List<FaultInfo> faults)
          Sets the list of fault elements.
 void setGrammars(GrammarsInfo grammars)
          Sets the grammars element.
 void setMethods(java.util.List<MethodInfo> methods)
          Sets the list of documentation elements.
 void setNamespaces(java.util.Map<java.lang.String,java.lang.String> namespaces)
          Sets the map of namespaces used in the WADL document.
 void setRepresentations(java.util.List<RepresentationInfo> representations)
          Sets the list of representation elements.
 void setResources(ResourcesInfo resources)
          Sets the list of resource elements.
 void setResourceTypes(java.util.List<ResourceTypeInfo> resourceTypes)
          Sets the list of resource type elements.
 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

ApplicationInfo

public ApplicationInfo()
Constructor.


ApplicationInfo

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

Parameters:
documentation - A single documentation element.

ApplicationInfo

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

Parameters:
documentations - The list of documentation elements.

ApplicationInfo

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

Parameters:
documentation - A single documentation element.
Method Detail

getFaults

public java.util.List<FaultInfo> getFaults()
Returns the list of fault elements.

Returns:
The list of fault elements.

getGrammars

public GrammarsInfo getGrammars()
Returns the grammar elements.

Returns:
The grammar elements.

getMethods

public java.util.List<MethodInfo> getMethods()
Returns the list of method elements.

Returns:
The list of method elements.

getNamespaces

public java.util.Map<java.lang.String,java.lang.String> getNamespaces()
Returns the map of namespaces used in the WADL document.

Returns:
The ap of namespaces used in the WADL document.

getRepresentations

public java.util.List<RepresentationInfo> getRepresentations()
Returns the list of representation elements.

Returns:
The list of representation elements.

getResources

public ResourcesInfo getResources()
Returns the resources root element.

Returns:
The resources root element.

getResourceTypes

public java.util.List<ResourceTypeInfo> getResourceTypes()
Returns the list of resource type elements.

Returns:
The list of resource type elements.

setFaults

public void setFaults(java.util.List<FaultInfo> faults)
Sets the list of fault elements.

Parameters:
faults - The list of documentation elements.

setGrammars

public void setGrammars(GrammarsInfo grammars)
Sets the grammars element.

Parameters:
grammars - The grammars element.

setMethods

public void setMethods(java.util.List<MethodInfo> methods)
Sets the list of documentation elements.

Parameters:
methods - The list of method elements.

setNamespaces

public void setNamespaces(java.util.Map<java.lang.String,java.lang.String> namespaces)
Sets the map of namespaces used in the WADL document. The key is the URI of the namespace and the value, the prefix.

Parameters:
namespaces - The map of namespaces used in the WADL document.

setRepresentations

public void setRepresentations(java.util.List<RepresentationInfo> representations)
Sets the list of representation elements.

Parameters:
representations - The list of representation elements.

setResources

public void setResources(ResourcesInfo resources)
Sets the list of resource elements.

Parameters:
resources - The list of resource elements.

setResourceTypes

public void setResourceTypes(java.util.List<ResourceTypeInfo> resourceTypes)
Sets the list of resource type elements.

Parameters:
resourceTypes - The list of resource type elements.

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.