Skip to content

Getting started with Java

To call the Document Filters engine from your Java application, you will need to use the classes included in ISYS11df.jar that form the com.perceptive.documentfilters package.

The classes in the package use JNI via the ISYS11dfjava.dll / libISYS11dfjava.so / libISYS11dfjava.dylib files, which call the native methods exported by the Document Filters engine. You will need to include both the JAR and the DLL / shared objects with your Java application.

The primary factory class in the com.perceptive.docfilters package is DocumentFilters. It is used to create Extractor objects that provide text extraction and sub-document enumeration facilities.

The recommended stack size is a minimum of 512kb with a heap of 512mb. It is not uncommon for different JVM vendors to use varying stack and heap sizes. Not all operations or implementations of DocumentFilters utilize this much space, but it is a good estimation for more involved processes.

Handling Exceptions

In Java and C#, every method of the API can throw an IGRException. In Java, this is a checked expression.

The IGRException class includes an errorCode and a Message. The errorCode represents one of the Result Codes listed in Constants and codes. The Message string may provide additional information about the error.

Java Implementation C# Implementation Description
java.lang.Exception System.Exception Base Class
int getErrorCode() [read-only property]int errorCode Retrieve the Error Code
string getMessage [read-only property]string Message Retrieve the Error Message