Currently you have to make choice to use a virtualizer or not before report generation.
Using a virtualizer at runtime after some point depending on some parameters would be really good.
But this shouldnt be a performance bottleneck also.
Option 1: (Memory Usage & Page Count for memory check)
-getObjectSize interface : I am not really sure, this can be done without performance loss. Iteration over page elements could be really expensive. (also implementing interface for each element seems not possible and a good solution)
Option 2: (Current page size)
This is not a elegant solution but maybe it could be the only one :)
After current page size exceeding a parameterized number, current jasperprint object can be virtualized. This seems to have most efficient way to do this.
any ideas ? :)