Java 类net.sf.jasperreports.engine.util.JRSwapFile 实例源码

项目:dynamicreports-jasper    文件:ConcatenatedReport3Test.java   
@Before
public void init() {
    JasperReportBuilder report1 = report()
        .title(cmp.text("text1"))
        .pageFooter(cmp.pageNumber());
    JasperReportBuilder report2 = report()
        .title(cmp.text("text2"))
        .pageFooter(cmp.pageNumber());
    JasperReportBuilder report3 = report()
        .title(cmp.text("text3"))
        .pageFooter(cmp.pageNumber());

    JRSwapFile swapFile = new JRSwapFile(System.getProperty("java.io.tmpdir"), 2000, 5000);
    concatenatedReport = concatenatedReport(new JasperPrintListFileHandler(System.getProperty("java.io.tmpdir"), new JRSwapFileVirtualizer(3, swapFile)));
    concatenatedReport.continuousPageNumbering();
    concatenatedReport.concatenate(report1, report2, report3);
}
项目:jasperreports    文件:JRSwapFileVirtualizer.java   
/**
 * Creates a virtualizer that uses a swap file.
 * <p>
 * The virtualizer will be considered the owner of the swap file.
 * 
 * @param maxSize the maximum size (in JRVirtualizable objects) of the paged in cache.
 * @param swap the swap file to use for data virtualization
 */
public JRSwapFileVirtualizer(int maxSize, JRSwapFile swap)
{
    this(maxSize, swap, true);
}
项目:jasperreports    文件:JRSwapFileVirtualizer.java   
/**
 * Creates a virtualizer that uses a swap file.
 * 
 * @param maxSize the maximum size (in JRVirtualizable objects) of the paged in cache.
 * @param swap the swap file to use for data virtualization
 * @param swapOwner whether the virtualizer is the owner (single user) of the swap file.
 * If <code>true</code>, the virtualizer will dispose the swap file on
 * {@link #cleanup() cleanup}.
 */
public JRSwapFileVirtualizer(int maxSize, JRSwapFile swap, boolean swapOwner)
{
    super(maxSize, new SwapFileVirtualizerStore(swap, swapOwner));
}
项目:jasperreports    文件:JRSwapFileVirtualizer.java   
/**
 * Creates a virtualizer that uses a swap file.
 * 
 * @param maxSize the maximum size (in JRVirtualizable objects) of the paged in cache.
 * @param swap the swap file to use for data virtualization
 * @param swapOwner whether the virtualizer is the owner (single user) of the swap file.
 * If <code>true</code>, the virtualizer will dispose the swap file on
 * {@link #cleanup() cleanup}.
 * @param compression stream compression to apply to serialized data
 */
public JRSwapFileVirtualizer(int maxSize, JRSwapFile swap, boolean swapOwner,
        StreamCompression compression)
{
    super(maxSize, new SwapFileVirtualizerStore(swap, swapOwner, compression));
}