Author: sylvain
Date: Wed Feb 9 12:18:20 2005
New Revision: 153113
URL: http://svn.apache.org/viewcvs?view=rev&rev=153113
Log:
switching back to the old (inconsistent) behaviour where request properties are
its parameters
Modified:
cocoon/trunk/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
cocoon/trunk/status.xml
Modified:
cocoon/trunk/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
URL:
http://svn.apache.org/viewcvs/cocoon/trunk/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java?view=diff&r1=153112&r2=153113
==============================================================================
---
cocoon/trunk/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
(original)
+++
cocoon/trunk/src/java/org/apache/cocoon/components/flow/javascript/fom/FOM_Cocoon.java
Wed Feb 9 12:18:20 2005
@@ -463,6 +463,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;
@@ -473,16 +477,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;
@@ -503,6 +509,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/trunk/status.xml
URL:
http://svn.apache.org/viewcvs/cocoon/trunk/status.xml?view=diff&r1=153112&r2=153113
==============================================================================
--- cocoon/trunk/status.xml (original)
+++ cocoon/trunk/status.xml Wed Feb 9 12:18:20 2005
@@ -472,8 +472,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