While working on a logicsheet I discovered a strange
behavior. Can anyone verify that the following might
be a bug:
This is just a stupid example:
<xsp:logic>
Iterator i;
while( i.hasNext() ) {
Object o = i.next();
<xsp:element name="iteration">
<xsp:logic>
if (o instanceof String) {
<xsp:attribute name="type">String</xsp:attribute> <---- NOTE THIS
}
</xsp:logic>
<xsp:attribute name="value"><xsp:expr>String.valueOf(o)</xsp:expr></xsp:attribute>
<xsp:expr>String.valueOf(o)</xsp:expr>
</xsp:element>
}
</xsp:logic>
Becomes:
Iterator i;
while( i.hasNext() ) {
Object o = i.next();
xspAttr.addAttribute("","value","value","CDATA",String.valueOf(String.valueOf(o)) +
"");
-->this.contentHandler.startElement("","iteration","iteration",xspAttr);
xspAttr.clear();
if (o instanceof String) {
--> xspAttr.addAttribute("","type","type","CDATA","String" + "");
}
XSPObjectHelper.xspExpr(contentHandler,String.valueOf(o));
this.contentHandler.endElement("","iteration","iteration");
}
As you see the xsp:attribute inside the xsp:logic tag is not part of the desired
element.
Did I miss something or is this a bug?
--
Torsten
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]