Update of /cvsroot/displaytag/displaytag/src/org/apache/taglibs/display
In directory sc8-pr-cvs1:/tmp/cvs-serv6193/src/org/apache/taglibs/display
Modified Files:
TableTag.java
Log Message:
Fixing the local.properties so you can checkout and build;
Corrected the use of StringBuffer.append(StringBuffer) for 1.3 compatibility.
Index: TableTag.java
===================================================================
RCS file: /cvsroot/displaytag/displaytag/src/org/apache/taglibs/display/TableTag.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** TableTag.java 23 Mar 2003 20:54:47 -0000 1.5
--- TableTag.java 29 Mar 2003 13:30:08 -0000 1.6
***************
*** 689,700 ****
// want HTML/XML/CSV/PDF/etc...
if( this.exportType == EXPORT_TYPE_NONE ) {
! buf.append( this.getHTMLData( viewableData ) );
} else if( this.exportType == EXPORT_TYPE_CSV ) {
! buf.append( this.getRawData( viewableData ) );
} else if( this.exportType == EXPORT_TYPE_EXCEL ) {
! buf.append( this.getExcelData( viewableData ) );
} else if( this.exportType == EXPORT_TYPE_XML ) {
! buf.append( this.getXMLData( viewableData ) );
}
--- 689,701 ----
// want HTML/XML/CSV/PDF/etc...
+ /* JBO 2003/03/29: I added the toString() for 1.3 compatibility */
if( this.exportType == EXPORT_TYPE_NONE ) {
! buf.append( this.getHTMLData( viewableData ).toString() );
} else if( this.exportType == EXPORT_TYPE_CSV ) {
! buf.append( this.getRawData( viewableData ).toString() );
} else if( this.exportType == EXPORT_TYPE_EXCEL ) {
! buf.append( this.getExcelData( viewableData ).toString() );
} else if( this.exportType == EXPORT_TYPE_XML ) {
! buf.append( this.getXMLData( viewableData ).toString() );
}
***************
*** 747,751 ****
Iterator iterator = null;
!
if( o instanceof Collection ) {
iterator = ( (Collection)o ).iterator();
--- 748,752 ----
Iterator iterator = null;
!
if( o instanceof Collection ) {
iterator = ( (Collection)o ).iterator();
***************
*** 754,758 ****
} else if( o instanceof Map ) {
iterator = ( (Map)o ).entrySet().iterator();
! /*
* This depends on importing struts.util.* -- see remarks in the import
section of the file
*
--- 755,759 ----
} else if( o instanceof Map ) {
iterator = ( (Map)o ).entrySet().iterator();
! /*
* This depends on importing struts.util.* -- see remarks in the import
section of the file
*
***************
*** 810,814 ****
* (though functional -- I tested). Furthermore, RowSetDynaClass
* is not yet officially released, so I'm leaving this out for
! * now.
*
* Anyway, the proper semantics would involve a class like ResultSetDynaClass,
--- 811,815 ----
* (though functional -- I tested). Furthermore, RowSetDynaClass
* is not yet officially released, so I'm leaving this out for
! * now.
*
* Anyway, the proper semantics would involve a class like ResultSetDynaClass,
***************
*** 822,826 ****
* }
*/
!
if( collection.getClass().isArray() )
collection = Arrays.asList( (Object[])collection );
--- 823,827 ----
* }
*/
!
if( collection.getClass().isArray() )
collection = Arrays.asList( (Object[])collection );
***************
*** 913,917 ****
if (! (viewableData instanceof List))
throw new RuntimeException ("This function is only supported if the given
collection is a java.util.List.");
!
// At this point we have all the objects that are supposed to be shown
--- 914,918 ----
if (! (viewableData instanceof List))
throw new RuntimeException ("This function is only supported if the given
collection is a java.util.List.");
!
// At this point we have all the objects that are supposed to be shown
***************
*** 963,967 ****
int rowcnt = 0;
! buf.append( this.getTableHeader() );
Iterator iterator = viewableData.iterator();
--- 964,968 ----
int rowcnt = 0;
! buf.append( this.getTableHeader().toString() );
Iterator iterator = viewableData.iterator();
***************
*** 1008,1012 ****
buf.append( "<td " );
! buf.append( tag.getCellAttributes() );
buf.append( ">" );
--- 1009,1013 ----
buf.append( "<td " );
! buf.append( tag.getCellAttributes().toString() );
buf.append( ">" );
***************
*** 1140,1144 ****
try {
//System.err.println ( "Tag getGroup : " + tag.getGroup() );
! buf.append( this.groupColumns( value.toString(), new Integer(
(String)tag.getGroup() ).intValue() ) );
} catch( Exception e ) {
System.err.println( e.getMessage() );
--- 1141,1145 ----
try {
//System.err.println ( "Tag getGroup : " + tag.getGroup() );
! buf.append( this.groupColumns( value.toString(), new Integer(
(String)tag.getGroup() ).intValue() ).toString() );
} catch( Exception e ) {
System.err.println( e.getMessage() );
***************
*** 1154,1158 ****
value.toString().length() ) + "</a>" );
} else {
! buf.append( value );
}
--- 1155,1159 ----
value.toString().length() ) + "</a>" );
} else {
! buf.append( value.toString() );
}
***************
*** 1196,1200 ****
! buf.append( this.getTableFooter() );
buf.append( "</table>\n" );
--- 1197,1201 ----
! buf.append( this.getTableFooter().toString() );
buf.append( "</table>\n" );
***************
*** 1280,1284 ****
buf.append( "\"" + value + "\"" );
} else {
! buf.append( value );
}
--- 1281,1285 ----
buf.append( "\"" + value + "\"" );
} else {
! buf.append( value.toString() );
}
***************
*** 1475,1479 ****
buf.append( "<table " );
! buf.append( this.getTableAttributes() );
buf.append( ">\n" );
--- 1476,1480 ----
buf.append( "<table " );
! buf.append( this.getTableAttributes().toString() );
buf.append( ">\n" );
-------------------------------------------------------
This SF.net email is sponsored by:
The Definitive IT and Networking Event. Be There!
NetWorld+Interop Las Vegas 2003 -- Register today!
http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en
_______________________________________________
displaytag-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/displaytag-devel