How to use MemoryExtender

Hallo Support-Team,
I found the class MemoryExtender in Aspose-PDF. I am very interested in using this, because in our product we have to handle also some really big pdf. Sometimes the gc() is so busy, that it stops the complete system. Could you please give an example, how to use it? Preferable how to set a directory, where the temp-files should be located? And one question more: Is this a setting, which can be done once, when system ist starting?
Thank you and kind regards, Gerd

@GRein

The MemoryExtender Class is helpful while using large files on a system with limited heap memory, as it can be enabled to use disk space as a temporary swap memory. Further information about it can be found in the attached link. A sample usage of the class will be as following:

Document doc = new Document(dataDir+"input.pdf");
MemoryExtender.setSkipHeavyContentEnabled(true);
doc.convert(dataDir + "log.log", PdfFormat.PDF_A_1A, ConvertErrorAction.Delete);