Here is an analysis of my heap dump. I've modified the Java program a
little bit, removing the String object creation, and making it a compound
statement instead, to reduce String object leaks. If the table looks
funny, try changing the text to a monospaced format, like Courier. I guess
my first question is, did I code the Java correctly. I made it 'static',
and I'm not really clear on what that means when calling from RPG. I see
that quite a few of the HSSF api's are not static, so I'm suspicious that I
might have setup my methods incorrectly:

public static void Text(HSSFRow row, int col, byte[] array, HSSFCellStyle
style ) {

HSSFCell cell = row.createCell(col);
cell.setCellType(1);
cell.setCellValue(new HSSFRichTextString(new String(array)));
cell.setCellStyle(style);
}


Class Name | Objects |
Shallow Heap
--------------------------------------------------------------------------------------
| |
org.apache.poi.hssf.usermodel.HSSFCell | 724,461 |
28,978,440
org.apache.poi.hssf.record.NumberRecord | 550,463 |
17,614,816
org.apache.poi.hssf.record.LabelSSTRecord | 173,998 |
5,567,936
org.apache.poi.hssf.record.CellValueRecordInterface[] | 28,996 |
5,101,712
org.apache.poi.hssf.usermodel.HSSFCell[] | 28,996 |
5,101,664
org.apache.poi.hssf.usermodel.HSSFRichTextString | 173,998 |
4,175,952
org.apache.poi.hssf.record.RowRecord | 28,996 |
1,391,808
java.lang.Integer | 57,992 |
927,872
org.apache.poi.hssf.usermodel.HSSFRow | 28,996 |
927,872
java.lang.Object[] | 1,851 |
498,640
org.apache.poi.hssf.record.CellValueRecordInterface[][] | 4 |
123,184
java.util.TreeMap$Node | 912 |
51,072
java.util.ArrayList | 26 |
832
org.apache.poi.hssf.record.ColumnInfoRecord | 16 |
640
java.util.HashMap$Entry[] | 8 |
640
java.util.TreeMap | 8 |
384
java.util.HashMap | 8 |
384
org.apache.poi.hssf.model.Sheet | 4 |
384
org.apache.poi.hssf.record.PrintSetupRecord | 4 |
256
org.apache.poi.hssf.record.aggregates.PageSettingsBlock | 4 |
256
org.apache.poi.hssf.record.BOFRecord | 4 |
160
org.apache.poi.hssf.record.WindowTwoRecord | 4 |
160
org.apache.poi.hssf.usermodel.HSSFSheet | 4 |
160
org.apache.poi.hssf.record.aggregates.RowRecordsAggregate | 4 |
160
org.apache.poi.hssf.record.SelectionRecord | 4 |
128
org.apache.poi.hssf.record.HeaderRecord | 4 |
128
org.apache.poi.hssf.record.DimensionsRecord | 4 |
128
org.apache.poi.hssf.record.FooterRecord | 4 |
128
org.apache.poi.hssf.util.CellRangeAddress8Bit | 4 |
128
org.apache.poi.hssf.record.GutsRecord | 4 |
128
char[] | 1 |
120
org.apache.poi.hssf.record.aggregates.ValueRecordsAggregate| 4 |
96
org.apache.poi.hssf.record.DeltaRecord | 4 |
96
org.apache.poi.hssf.record.DefaultRowHeightRecord | 4 |
96
org.apache.poi.hssf.record.WSBoolRecord | 4 |
96
org.apache.poi.hssf.record.HorizontalPageBreakRecord | 4 |
96
org.apache.poi.hssf.record.VerticalPageBreakRecord | 4 |
96
org.apache.poi.hssf.util.CellRangeAddress8Bit[] | 4 |
96
org.apache.poi.hssf.record.CalcCountRecord | 4 |
64
Total: 39 of 60 entries | 1,799,874 |
70,468,176
--------------------------------------------------------------------------------------


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2022 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.