Working with PDF Utilities working-with-pdf-utilities
About the PDF Utilities Service
The PDF Utilities service can convert between PDF and XDP file formats, set and retrieve PDF document properties, and manipulate XMP metadata. For example, before converting a PDF document to another format, it is useful to inspect its properties to determine which service operation to invoke for the conversion.
You can accomplish these tasks using the PDF Utilities service:
- Convert PDF documents to XDP documents.
- Convert XDP documents to PDF documents. (See Converting XDP Documents into PDF Documents.)
- Retrieve PDF document properties. (See Retrieving PDF Document Properties.)
- Save a PDF document and optimize it for fast web viewing. (See Setting PDF Document Save Modes.)
Converting PDF Documents into XDP Documents converting-pdf-documents-into-xdp-documents
You can use the PDF Utilities Java and web service APIs to programmatically convert PDF documents into XDP documents.
Summary of steps summary-of-steps
To convert a PDF document into an XDP document, perform the following steps:
- Include project files.
- Create a PDFUtilityService client.
- Invoke the PDF to XDP conversion operation.
Include project files
Include necessary files into your development project. If you are creating a client application using Java, include the necessary JAR files. If you are using web services, ensure that you include the proxy files.
Create a PDFUtilityService client
Before you can programmatically perform a PDF Utilities operation, you must create a PDFUtilityService client. With the Java API, this is accomplished by creating a PDFUtilityServiceClient object. With the web service API, this is accomplished by using a PDFUtilityServiceService object.
Invoke the PDF to XDP conversion operation
After you create the service client, you can invoke the PDF to XDP conversion operation.
See also
Convert PDF documents into XDP documents using the Java API
Convert PDF documents into XDP documents using the web service API
Including AEM Forms Java library files
Convert PDF documents into XDP documents using the Java API convert-pdf-documents-into-xdp-documents-using-the-java-api
Convert PDF documents into XDP documents by using the PDF Utilities API(Java):
-
Include project files
Include client JAR files, such as the adobe-pdfutility-client.jar, in your Java project’s class path…
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceClientobject by using its constructor and passing aServiceClientFactoryobject that contains connection properties. -
Invoke the PDF to XDP conversion operation
To perform the conversion, invoke the
PDFUtilityServiceClientobject’sconvertPDFtoXDPmethod and pass in acom.adobe.idp.Documentobject that represents the PDF file. The method returns acom.adobe.idp.Documentobject that represents the newly created XDP file.
See also
Converting PDF Documents into XDP Documents
Convert PDF documents into XDP documents using the web service API convert-pdf-documents-into-xdp-documents-using-the-web-service-api
Convert PDF documents into XDP documents by using the PDF Utilities API (web service):
-
Include project files
- Create a Microsoft .NET client assembly that consumes the PDF Utilities service WSDL file.
- Reference the Microsoft .NET client assembly.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceServiceobject by using your proxy class constructor. -
Invoke the PDF to XDP conversion operation
Invoke the
PDFUtilityServiceServiceobject’sconvertPDFtoXDPmethod and pass in aBLOBobject that represents the PDF file. The method returns aBLOBobject that represents the newly created XDP file.
See also
Converting PDF Documents into XDP Documents
Invoking AEM Forms using Base64 encoding
Creating a .NET client assembly that uses Base64 encoding
Converting XDP Documents into PDF Documents converting-xdp-documents-into-pdf-documents
You can use the PDF Utilities Java and web service APIs to programmatically convert XDP documents into PDF documents.
Summary of steps summary_of_steps-1
To convert an XDP document into a PDF document, perform the following steps:
- Include project files.
- Create a PDFUtilityService client.
- Invoke the XDP to PDF conversion operation.
Include project files
Include necessary files into your development project. If you are creating a client application using Java, include the necessary JAR files. If you are using web services, ensure that you include the proxy files.
Create a PDFUtilityService client
Before you can programmatically perform a PDF Utilities operation, you must create a PDFUtilityService client. With the Java API, this is accomplished by creating a PDFUtilityServiceClient object. With the web service API, this is accomplished by using a PDFUtilityServiceService object.
Invoke the XDP to PDF conversion operation
After you create the service client, you can invoke the XDP to PDF conversion operation.
See also
Convert XDP documents into PDF documents using the Java API
Converting XDP documents into PDF documents using the web service API
Convert XDP documents into PDF documents using the Java API convert-xdp-documents-into-pdf-documents-using-the-java-api
Convert XDP documents into PDF documents by using the PDF Utilities API (Java):
-
Include project files
Include client JAR files, such as adobe-pdfutility-client.jar, in your Java project’s class path.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceClientobject by using its constructor and passing aServiceClientFactoryobject that contains connection properties. -
Invoke the XDP to PDF conversion operation
To perform the conversion, invoke the
PDFUtilityServiceClientobject’sconvertXDPtoPDFmethod and pass in acom.adobe.idp.Documentobject that represents the XDP file. The method returns acom.adobe.idp.Documentobject that represents the newly created PDF file.
See also
Converting XDP Documents into PDF Documents
Including AEM Forms Java library files
Converting XDP documents into PDF documents using the web service API converting-xdp-documents-into-pdf-documents-using-the-web-service-api
Convert XDP documents into PDF documents by using the PDF Utilities API (web service API):
-
Include project files
- Create a Microsoft .NET client assembly that consumes the PDF Utilities service WSDL file.
- Reference the Microsoft .NET client assembly.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceServiceobject by using your proxy class constructor. -
Invoke the XDP to PDF conversion operation
To perform the conversion, invoke the
PDFUtilityServiceServiceobject’sconvertXDPtoPDFmethod and pass in aBLOBobject that represents the XDP file. The method returns aBLOBobject that represents the newly created PDF file.
See also
Converting XDP Documents into PDF Documents
Retrieving PDF Document Properties retrieving-pdf-document-properties
You can use the PDF Utilities Java and web service APIs to programmatically retrieve PDF document properties, such as whether the document is a fillable form or the minimum Acrobat version required to read the document.
Summary of steps summary_of_steps-2
To retrieve PDF document properties, perform the following steps:
- Include project files.
- Create a PDFUtilityService client.
- Invoke the properties retrieval operation.
Include project files
Include necessary files into your development project. If you are creating a client application using Java, include the necessary JAR files. If you are using web services, ensure that you include the proxy files.
Create a PDFUtilityService client
Before you can programmatically perform a PDF Utilities operation, you must create a PDFUtilityService client. With the Java API, this is accomplished by creating a PDFUtilityServiceClient object. With the web service API, this is accomplished using a PDFUtilityServiceService object.
Invoke the properties retrieval operation
After you create the service client, you can invoke the properties retrieval operation.
See also
Retrieve PDF document properties using the Java API
Retrieve PDF document properties using the web service API
Retrieve PDF document properties using the Java API retrieve-pdf-document-properties-using-the-java-api
Retrieve PDF document properties by using the PDF Utilities API (Java):
-
Include project files
Include client JAR files, such as adobe-pdfutility-client.jar, in your Java project’s class path.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceClientobject by using its constructor and passing aServiceClientFactoryobject that contains connection properties. -
Invoke the properties retrieval operation
To perform the conversion, invoke the
PDFUtilityServiceClientobject’sgetPDFPropertiesmethod and pass in the following:- A
com.adobe.idp.Documentobject that represents the PDF document. - A
PDFPropertiesOptionSpecobject that contains the properties to be evaluated.
The method returns a
PDFPropertiesResultobject that contains the results of the query. - A
See also
Retrieving PDF Document Properties
Including AEM Forms Java library files
Retrieve PDF document properties using the web service API retrieve-pdf-document-properties-using-the-web-service-api
Retrieve PDF document properties by using the PDF Utilities web service API:
-
Include project files
- Create a Microsoft .NET client assembly that consumes the PDF Utilities service WSDL file.
- Reference the Microsoft .NET client assembly.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceServiceobject by using your proxy class constructor. -
Invoke the properties retrieval operation
To perform the conversion, invoke the
PDFUtilityServiceServiceobject’sgetPDFPropertiesmethod and pass in the following:- A
BLOBobject that represents the PDF document. - A
PDFPropertiesOptionSpecobject that contains the properties to be evaluated.
The method returns a
PDFPropertiesResultobject that contains the results of the query. - A
See also
Retrieving PDF Document Properties
Setting PDF Document Save Modes setting-pdf-document-save-modes
You can use the PDF Utilities service Java and web service APIs to programmatically set a save mode for a PDF document. When using the PDF Utilities service to set a save mode, the PDF Utilities service only sets the save mode and does not actually save the PDF document. The PDF document is saved when it is passed to another service operation. For example, you can use the PDF Utilities service to set a specific save mode and pass it to the Encryption service, where the PDF document is actually saved and encrypted.
Summary of steps summary_of_steps-3
To set the save option for PDF documents, perform the following steps:
- Include project files.
- Create a PDFUtilityService client.
- Set the save mode.
- Invoke the save operation.
- Pass the PDF document to another operation.
Include project files
Include necessary files into your development project. If you are creating a client application using Java, include the necessary JAR files. If you are using web services, ensure that you include the proxy files.
Create a PDFUtilityService client
Before you can programmatically perform a PDF Utilities operation, you must create a PDFUtilityService client. With the Java API, this is accomplished by creating a PDFUtilityServiceClient object. With the web service API, this is accomplished using a PDFUtilityServiceService object.
Set the Save mode
You can choose one of the following save options:
INCREMENTAL: To save incrementally to reduce the time required to saveFAST_WEB_VIEW: save for fast web viewingFULL: To save using a full save (without optimizations)
Invoke the save style operation
After you create the service client, you can invoke the properties retrieval operation.
Pass the PDF document to another AEM Forms operation
Once the PDF Utilities service sets the specified Save mode, pass the PDF document to another AEM Forms operation. Once returned from that operation, the PDF document is saved in the specified mode. For example, if you use the PDF Utilities service to set the FAST_WEB_VIEW mode and then pass the PDF document to the Encryption service’s encryptUsingPassword operation, the returned PDF document is encrypted with a password and save in the FAST_WEB_VIEW mode.
FAST_WEB_VIEW mode and then passes the PDF document to the Encryption service’s encryptUsingPassword operation.See also
Set PDF document save options using the Java API
Set PDF document save options using the web service API
Set PDF document save options using the Java API set-pdf-document-save-options-using-the-java-api
Set the PDF document save options by using the PDF Utilities API (Java):
-
Include project files
Include client JAR files, such as adobe-pdfutility-client.jar, in your Java project’s class path.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceClientobject by using its constructor and passing aServiceClientFactoryobject that contains connection properties. -
Set the Save mode
- Create a
PDFUtilitySaveModeobject by using its constructor. - Set the save mode by invoking the
PDFUtilitySaveModeobject’ssetSaveStylemethod and passing a string value that specifies the save mode. For example, to save for fast web viewing, passFAST_WEB_VIEW.
- Create a
-
Invoke the save style operation
Invoke the
PDFUtilityServiceClientobject’ssetSaveModemethod and pass the following values:- A
com.adobe.idp.Documentobject that represents the PDF document. - A
PDFUtilitySaveModeobject that contains the save style to be used. - A Boolean value used to determine whether to override any previous settings.
The method returns a
com.adobe.idp.Documentobject formatted using the specified save style. - A
-
Pass the PDF document to another AEM Forms operation
- Pass the returned
com.adobe.idp.Documentobject to another AEM Forms operation.
- Pass the returned
See also
Setting PDF Document Save Modes
Set PDF document save options using the web service API set-pdf-document-save-options-using-the-web-service-api
Set the PDF document save options by using the PDF Utilities AP (web service):
-
Include project files
- Create a Microsoft .NET client assembly that consumes the PDF Utilities service WSDL file.
- Reference the Microsoft .NET client assembly.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceServiceobject by using your proxy class constructor. -
Set the Save mode
- Create a
PDFUtilitySaveModeobject by using its constructor. - Set the save mode by assigning a string value to the
PDFUtilitySaveModeobject’ssaveStylemethod that specifies the save mode. For example, to save for fast web viewing, specifyFAST_WEB_VIEW.
- Create a
-
Invoke the save style operation
Invoke the
PDFUtilityServiceServiceobject’ssetSaveModemethod and pass the following values:- A
BLOBobject that represents the PDF document. - A
PDFUtilitySaveModeobject that contains the save style to be used. - A Boolean value used to determine whether to override any previous settings.
The method returns a
BLOBobject formatted using the specified save style. You can then save that object as a PDF document. - A
-
Pass the PDF document to another Forms operation
- Pass the returned
BLOBobject to another AEM Forms operation.
- Pass the returned
See also
Setting PDF Document Save Modes
Sanitizing PDF Documents sanitizing-pdf-documents
You can use the PDF Utilities Java APIs to programmatically convert PDF documents into XDP documents.
Summary of steps summary_of_steps-4
To sanitize PDF document, perform the following steps:
- Include project files.
- Create a PDFUtilityService client.
- Invoke the sanitization operation.
Include project files
Include necessary files into your development project. To create a client application using Java, include the necessary JAR files.
Create a PDFUtilityService client
Before you can programmatically perform a sanitization operation, you must create a PDFUtilityService client. With the Java API, this is accomplished by creating a PDFUtilityServiceClient object.
Invoke the PDF to XDP conversion operation
After you create the service client, you can invoke the sanitization operation.
See also
Convert PDF documents into XDP documents using the Java API
Convert PDF documents into XDP documents using the web service API
Including AEM Forms Java library files
Sanitize PDF documents using the Java API sanitize-pdf-documents-using-the-java-api
Sanitize documents by using the PDF Utilities API (Java):
-
Include project files
Include client JAR files, such as the adobe-pdfutility-client.jar, in your Java project’s class path.
-
Create a PDFUtilityService client
Create a
PDFUtilityServiceClientobject by using its constructor and passing aServiceClientFactoryobject that contains connection properties. -
Invoke the PDF to XDP conversion operation
To perform the conversion, invoke the
PDFUtilityServiceClientobject’sconvertPDFtoXDPmethod and pass in acom.adobe.idp.Documentobject that represents the PDF file. The method returns acom.adobe.idp.Documentobject that represents the newly created XDP file.
See also
Including AEM Forms Java library files