Access to the current row in a column decorator
-----------------------------------------------
Key: DISPL-392
URL: http://jira.codehaus.org/browse/DISPL-392
Project: DisplayTag
Issue Type: New Feature
Components: Decorators
Affects Versions: 1.1
Reporter: Hani Suleiman
Fix For: 1.1.1
Attachments: patch.txt, RowAwareColumnDecorator.java
Currently it is not possible to get access to the current row within a column
decorator. Ideally, the API would be changed to pass this in, so a decorator
has access to more contexual information for cases where it needs to show
multiple links and so on within one cell.
However, for the sake of backward compatibility, the API cannot be changed. My
solution is to create a new class RowAwareColumnDecorator that's an abstract
implementation of DisplaytagColumnDecorator, with a get/setRowObject accessor.
The next change is Column.java, to check for this subclass, and if so, set the
row object before calling decorate.
Patch attached.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
displaytag-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/displaytag-devel