I want  to know if   my code below can  cause memory issues , 

            PdfPTable table = new PdfPTable(headers.length);

             // header code
            for (int i = 0; i < headers.length; i++) {
                String header = headers[i];
                PdfPCell cell = new PdfPCell();
                cell.setGrayFill(0.9f);
                cell.setPhrase(new Phrase(header.toUpperCase(), new
Font(Font.HELVETICA, 10, Font.BOLD)));
                table.addCell(cell);
            }
            table.completeRow();

        // row data code


            Iterator iterator = data.iterator();
            while (iterator.hasNext()) {
                String rowData[] = (String[]) iterator.next();
                for (int i = 0; i < rowData.length; i++) {
                    String datum = rowData[i];
                    PdfPCell cell = new PdfPCell();
                    cell.setPhrase(new Phrase(datum, new
Font(Font.HELVETICA, 10, Font.NORMAL)));
                    table.addCell(cell);
                }
                table.completeRow();
            }
table.setHeaderRows(1);
 

in my case data is a list and its size can be 20,000 or more ,

I saw this post 

http://blog.ropardo.ro/2009/09/25/itext-constructing-tables/

when I tried as per the post , the  header was repeating in every page,
should I worry abpout memory issues when working with itext pdftable and
lost of row data ?
-- 
View this message in context: 
http://itext-general.2136553.n4.nabble.com/creating-huge-pdf-tables-tp3258034p3258034.html
Sent from the iText - General mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to