cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sylv...@apache.org
Subject svn commit: r153112 - cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java cocoon/branches/BRANCH_2_1_X/status.xml
Date Wed, 09 Feb 2005 20:16:35 GMT
Author: sylvain
Date: Wed Feb  9 12:16:33 2005
New Revision: 153112

URL: http://svn.apache.org/viewcvs?view=rev&rev=153112
Log:
switching back to the old (inconsistent) behaviour where request properties are its parameters

Modified:
    cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
    cocoon/branches/BRANCH_2_1_X/status.xml

Modified: cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java?view=diff&r1=153111&r2=153112
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
Wed Feb  9 12:16:33 2005
@@ -466,6 +466,10 @@
 
     /**
      * JS wrapper for Cocoon's request object.
+     * <p>
+     * Request <em>parameters</em> are also present as properties on this object.
+     * Note that this is different from <code>FOM_Context</code> and <code>FOM_Session</code>
+     * that do the same with <em>attributes</em>.
      */
     public static class FOM_Request extends AttributeHolderJavaObject {
         private final Request request;
@@ -476,16 +480,18 @@
         }
         
         protected Enumeration getAttributeNames() {
-            return this.request.getAttributeNames();
+            return this.request.getParameterNames();
         }
         
         protected Object getAttribute(String name) {
-            return this.request.getAttribute(name);
+            return this.request.getParameter(name);
         }
     }
 
     /**
      * JS wrapper for Cocoon's session object.
+     * <p>
+     * Session attributes are also present as properties on this object.
      */
     public static class FOM_Session extends AttributeHolderJavaObject {
         private final Session session;
@@ -506,6 +512,8 @@
 
     /**
      * JS wrapper for Cocoon's context object.
+     * <p>
+     * Context attributes are also present as properties on this object.
      */
     public static class FOM_Context extends AttributeHolderJavaObject {
         private final org.apache.cocoon.environment.Context context;

Modified: cocoon/branches/BRANCH_2_1_X/status.xml
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/status.xml?view=diff&r1=153111&r2=153112
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/status.xml (original)
+++ cocoon/branches/BRANCH_2_1_X/status.xml Wed Feb  9 12:16:33 2005
@@ -205,8 +205,7 @@
    <action dev="SW" type="update">
     Remove restrictions on the flowscript object model (FOM): the objects available through
the
     <code>cocoon</code> object (request, session, response, etc) now provide
the full API of the
-    corresponding Java classes. The only additional feature of the JS objects are that request,
-    session and context attributes are available as properties on these objects.
+    corresponding Java classes.
    </action>
    <action dev="CZ" type="fix">
     CForms: template generator and transformer now use the same object model as the JXTG:
access



Mime
View raw message