luehe 2002/07/30 15:53:38
Modified: jasper2/src/share/org/apache/jasper/compiler Generator.java
Log:
When making a dynamic attribute available as a page scoped variable,
use <uri_namespace>_<localname> (if <uri_namespace> is passed in) or
just <localname> (otherwise) as the variable name.
Revision Changes Path
1.50 +10 -3
jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/Generator.java
Index: Generator.java
===================================================================
RCS file:
/home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/Generator.java,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -r1.49 -r1.50
--- Generator.java 30 Jul 2002 22:41:37 -0000 1.49
+++ Generator.java 30 Jul 2002 22:53:38 -0000 1.50
@@ -2910,7 +2910,14 @@
public void generateSetDynamicAttribute() {
out.printil("public void setDynamicAttribute(String uri, String localName,
Object value) throws AttributeNotSupportedException {");
out.pushIndent();
+ out.printil("if (uri != null)");
+ out.pushIndent();
+ out.printil("dynamicAttrs.put(uri + \"_\" + localName, value);");
+ out.popIndent();
+ out.printil("else");
+ out.pushIndent();
out.printil("dynamicAttrs.put(localName, value);");
+ out.popIndent();
out.popIndent();
out.printil("}");
}
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>