Skip to main content
Skip table of contents

PDF Splitter Iterator

PDF Splitter Iterator: Splits an unprotected PDF document into several new PDF documents.

This adapter expects an adapter-specific input XML structure which contains the path to the processed PDF document in the repository. The adapter outputs the data of a PDF part document as a binary data stream or as an XML document per iteration.

Properties

Operation

Determines which operation the adapter executes

Possible values:

  • Split Iterator: Split PDF document into multiple PDF documents

  • Clear: Reset iterator to initial value

Parameter

Adapter

Main class of the adapter (do not change!)

Possible values: de.softproject.integration.adapter.pdf.PDFSplitterIteratorAdapter: Main class (default)

Start

Page number from which to start

Possible values: Any positive integer

Step

Step size by which the Start parameter is incremented for the next iteration.

Possible values: Any positive integer

Count

Number of pages to be output as a separate PDF document per iteration.

Possible values: Any positive integer

toXML

Output PDF document Base64-encoded in an XML document

Possible values:

  • yes: Output XML document

  • no: Output PDF document as binary data stream (default).

ReadPartially

Load PDF document into memory in multiple parts (can improve the performance)

Possible values:

  • yes: Load in several parts one after the other into the working memory

  • no: Load PDF document(s) into memory in one piece (default)

Status values

1The operation was executed successfully.
0

The operation was executed successfully, but without any result.

-1The operation failed due to a technical error.

Input

This function adapter expects an adapter-specific input XML structure which contains the path to the processed PDF document in the repository or the Base64 string.

PDF in PDF format

The following input XML document contains the path to a PDF document in the repository.

HTML/XML
<?xml version="1.0" encoding="UTF-8"?>
<PDF url="xstore://Project/Folder/Input.pdf"/>

PDF in Base64 format

The following input XML document contains the Base64 string.

HTML/XML
<?xml version="1.0" encoding="UTF-8"?>
<PDF encoding="base64">
  Base64 string
</PDF>

Output

If the ToXML parameter is disabled, the output can be saved directly as a buffer file in PDF format.

If the ToXML parameter is enabled, the output looks like this:

XML
<?xml version="1.0" encoding="UTF-8"?>
<PDF encoding="base64">
	Base64 string
</PDF>

Example

The process splits the XML and stores all intermediate results in XML format in a variable. To store the variables, the X4 Variable Collector adapter is used.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.