Index: trunk/zoo-api/js/ZOO-api.js
===================================================================
--- trunk/zoo-api/js/ZOO-api.js	(revision 100)
+++ trunk/zoo-api/js/ZOO-api.js	(revision 101)
@@ -3628,4 +3628,18 @@
         result.uom = node.@uom;
       return result;
+    },
+    /**
+     * Method: parseData.reference
+     * Given an Object representing the WPS reference response.
+     *
+     * Parameters:
+     * node - {E4XElement} A WPS node.
+     *
+     * Returns:
+     * {Object} A WPS reference response.
+     */
+    'reference': function(node) {
+      var result = {type:'reference',value:node.*::href};
+      return result;
     }
   },
@@ -3849,5 +3863,5 @@
 });
 /**
- * Function: OpenLayers.Geometry.fromWKT
+ * Function: ZOO.Geometry.fromWKT
  * Generate a geometry given a Well-Known Text string.
  *
@@ -3992,5 +4006,5 @@
 };
 /**
- * Class: OpenLayers.Geometry.Collection
+ * Class: ZOO.Geometry.Collection
  * A Collection is exactly what it sounds like: A collection of different 
  * Geometries. These are stored in the local parameter <components> (which
@@ -5260,5 +5274,5 @@
  * 
  * Inherits:
- *  - <OpenLayers.Geometry.LineString>
+ *  - <ZOO.Geometry.LineString>
  */
 ZOO.Geometry.LinearRing = ZOO.Class(
@@ -5272,5 +5286,5 @@
   componentTypes: ["ZOO.Geometry.Point"],
   /**
-   * Constructor: OpenLayers.Geometry.LinearRing
+   * Constructor: ZOO.Geometry.LinearRing
    * Linear rings are constructed with an array of points.  This array
    *     can represent a closed or open ring.  If the ring is open (the last
@@ -5786,5 +5800,5 @@
   componentTypes: ["ZOO.Geometry.LinearRing"],
   /**
-   * Constructor: OpenLayers.Geometry.Polygon
+   * Constructor: ZOO.Geometry.Polygon
    * Constructor for a Polygon geometry. 
    * The first ring (this.component[0])is the outer bounds of the polygon and 
@@ -5977,5 +5991,5 @@
   componentTypes: ["ZOO.Geometry.Polygon"],
   /**
-   * Constructor: OpenLayers.Geometry.MultiPolygon
+   * Constructor: ZOO.Geometry.MultiPolygon
    * Create a new MultiPolygon geometry
    *
@@ -5990,7 +6004,19 @@
   CLASS_NAME: "ZOO.Geometry.MultiPolygon"
 });
-
+/**
+ * Class: ZOO.Process
+ * Used to query OGC WPS process defined by its URL and its identifier. 
+ * Usefull for chaining localhost process.
+ */
 ZOO.Process = ZOO.Class({
+  /**
+   * Property: schemaLocation
+   * {String} Schema location for a particular minor version.
+   */
   schemaLocation: "http://www.opengis.net/wps/1.0.0/../wpsExecute_request.xsd",
+  /**
+   * Property: namespaces
+   * {Object} Mapping of namespace aliases to namespace URIs.
+   */
   namespaces: {
     ows: "http://www.opengis.net/ows/1.1",
@@ -5999,10 +6025,39 @@
     xsi: "http://www.w3.org/2001/XMLSchema-instance",
   },
+  /**
+   * Property: url
+   * {String} The OGC's Web PRocessing Service URL, 
+   *          default is http://localhost/zoo.
+   */
   url: 'http://localhost/zoo',
+  /**
+   * Property: identifier
+   * {String} Process identifier in the OGC's Web Processing Service.
+   */
   identifier: null,
+  /**
+   * Constructor: ZOO.Process
+   * Create a new Process
+   *
+   * Parameters:
+   * url - {String} The OGC's Web Processing Service URL.
+   * identifier - {String} The process identifier in the OGC's Web Processing Service.
+   *
+   */
   initialize: function(url,identifier) {
     this.url = url;
     this.identifier = identifier;
   },
+  /**
+   * Method: Execute
+   * Query the OGC's Web PRocessing Servcie to Execute the process.
+   *
+   * Parameters:
+   * inputs - {Object}
+   *
+   * Returns:
+   * {String} The OGC's Web processing Service XML response. The result 
+   *          needs to be interpreted.
+   */
   Execute: function(inputs) {
     if (this.identifier == null)
@@ -6013,5 +6068,20 @@
     return response;
   },
+  /**
+   * Property: buildInput
+   * Object containing methods to build WPS inputs.
+   */
   buildInput: {
+    /**
+     * Method: buildInput.complex
+     * Given an E4XElement representing the WPS complex data input.
+     *
+     * Parameters:
+     * identifier - {String} the input indetifier
+     * data - {Object} A WPS complex data input.
+     *
+     * Returns:
+     * {E4XElement} A WPS Input node.
+     */
     'complex': function(identifier,data) {
       var input = new XML('<wps:Input xmlns:wps="'+this.namespaces['wps']+'"><ows:Identifier xmlns:ows="'+this.namespaces['ows']+'">'+identifier+'</ows:Identifier><wps:Data><wps:ComplexData>'+data.value+'</wps:ComplexData></wps:Data></wps:Input>');
@@ -6024,7 +6094,29 @@
       return input;
     },
+    /**
+     * Method: buildInput.reference
+     * Given an E4XElement representing the WPS reference input.
+     *
+     * Parameters:
+     * identifier - {String} the input indetifier
+     * data - {Object} A WPS reference input.
+     *
+     * Returns:
+     * {E4XElement} A WPS Input node.
+     */
     'reference': function(identifier,data) {
       return '<wps:Input xmlns:wps="'+this.namespaces['wps']+'"><ows:Identifier xmlns:ows="'+this.namespaces['ows']+'">'+identifier+'</ows:Identifier><wps:Reference xmlns:xlink="'+this.namespaces['xlink']+'" xlink:href="'+data.value.replace('&','&amp;','gi')+'"/></wps:Input>';
     },
+    /**
+     * Method: buildInput.literal
+     * Given an E4XElement representing the WPS literal data input.
+     *
+     * Parameters:
+     * identifier - {String} the input indetifier
+     * data - {Object} A WPS literal data input.
+     *
+     * Returns:
+     * {E4XElement} The WPS Input node.
+     */
     'literal': function(identifier,data) {
       var input = new XML('<wps:Input xmlns:wps="'+this.namespaces['wps']+'"><ows:Identifier xmlns:ows="'+this.namespaces['ows']+'">'+identifier+'</ows:Identifier><wps:Data><wps:LiteralData>'+data.value+'</wps:LiteralData></wps:Data></wps:Input>');
@@ -6037,4 +6129,14 @@
     }
   },
+  /**
+   * Method: buildDataInputsNode
+   * Method to build the WPS DataInputs element.
+   *
+   * Parameters:
+   * inputs - {Object}
+   *
+   * Returns:
+   * {E4XElement} The WPS DataInputs node for Execute query.
+   */
   buildDataInputsNode:function(inputs){
     var data, builder, inputsArray=[];
