CompareTextBaselineBatchA
Small Business, comparison reports
Requires the Small Business edition — in Delphi, C++Builder and Lazarus code create the library as TPDFlibSmallBusiness (unit PDFlibSmallBusiness) or TPDFlibEnterprise; the Small Business and Enterprise DLL and ActiveX builds provide it unchanged; the Single edition keeps the method, which returns an empty string and sets LastErrorCode to 901 (PDFLIB_ERROR_SMALLBUSINESS_REQUIRED)
Requires Small Business or Enterprise
Description
The trailing A denotes the ANSI (char) DLL entry point; the ActiveX/COM surface exposes only the Unicode form. Behaviour is identical to CompareTextBaselineBatch and string arguments are interpreted using the current SetAnsiMode code page
Syntax
Delphi
Function DLCompareTextBaselineBatchA(InstanceID: Integer; RequestJSON: PAnsiChar): PAnsiChar;
DLL
const char* DLCompareTextBaselineBatchA(int InstanceID, const char* RequestJSON);
The request contains a jobs array of 1 through 64 objects; each specifies current and baseline file names, optional currentPassword and baselinePassword strings, and optional integer granularity of 0 or 1, defaulting to 0
{"jobs":[{"current":"revised.pdf","baseline":"approved.pdf","granularity":1}]}
Each pair is loaded into temporary instances; the caller's selected document is retained; failures are recorded per job and do not prevent later jobs from running
The JSON result includes status, complete, failedJobs, incompleteJobs and indexed jobs containing each raw text comparison or error
A valid batch envelope has status:"ok" even when individual jobs fail; inspect the counters and rows; invalid request schemas return status:"error" with error 905
Unknown members, duplicate keys, invalid types, malformed UTF-16 and excessive JSON work are rejected; comparison output is bounded to 16,777,216 UTF-16 code units plus the small batch envelope
DLL and Dylib provide DLCompareTextBaselineBatch and its A variant; ActiveX exposes the method through IPDFlibrary8