About the Output Service
The Output
service lets you output documents as PDF (including PDF/A documents),
PostScript, Printer Control Language (PCL), and the following label formats:
Zebra - ZPL
Intermec - IPL
Datamax - DPL
TecToshiba - TPCL
Using the Output service,
you can merge XML form data with a form design and output the document
to a network printer or file.
There are two ways in which
you can pass a form design (an XDP file) to the Output service.
You can either pass a com.adobe.idp.Document instance that
contains a form design to the Output service. Or you can pass a
URI value that specifies the location of the form design. Both of
these ways are discussed in Programming with LiveCycle.
Note: The Output service does not support Acroform PDF
documents that contain application object specific scripts. Acroform
PDF documents that contain application object specific scripts are
not rendered.
The following sections show how to pass
a form design to the Output service using a URI value:
The following sections show
how to pass a form design within a com.adobe.idp.Document instance:
One consideration
when deciding which technique to use is if you are getting the form
design from another LiveCycle service, then pass it within a com.adobe.idp.Document instance.
Both the Passing Documents to the Output Service and Creating PDF Documents using Fragments sections
show how to get a form design from another LiveCycle service. The
first section retrieves the form design from Content Services (deprecated).
The second section retrieves the form design from the Assembler
service.
If you are getting the form design from a fixed
location, such as the file system, then you can use either technique.
That is, you can specify the URI value to a XDP file or use a com.adobe.idp.Document instance.
To
pass a URI value that specifies the location of the form design
when creating a PDF document, use the generatePDFOutput method.
Likewise, to pass a com.adobe.idp.Document instance
to the Output service when creating a PDF document, use the generatePDFOutput2 method.
When
sending an output stream to a network printer, you can also use
either technique. To send an output stream to a printer by passing
a com.adobe.idp.Document instance that contains
a form design, use the sendToPrinter2 method. To
send an output stream to a printer by passing a URI value, use the sendToPrinter method.
The Sending Print Streams to Printers section uses the sendToPrinter method.
You
can accomplish these tasks by using the Output service: