com.adobe.convertpdf.docservice
Interface ConvertPdfService

All Known Implementing Classes:
ConvertPdfServiceImpl

public interface ConvertPdfService


Field Summary
static java.lang.String DRAW_SMOOTH_IMAGE
           
static java.lang.String DRAW_SMOOTH_LINE_ART
           
static java.lang.String DRAW_SMOOTH_TEXT
           
static java.lang.String THRESHOLD_RESOLUTION_FOR_SMOOTHING
          Parameters used in deciding whether to do smoothing or not for text,lineArt and image.
 
Method Summary
 int getThresholdResolutionForSmoothing()
          Returns the Threshold Resolution For Smoothing (in dpi).
 boolean isDrawSmoothImage()
          Returns the boolean flag that decides whether to apply smoothing functions to Images.
 boolean isDrawSmoothLineArt()
          Returns the boolean flag that decides whether to apply smoothing functions to LineArt.
 boolean isDrawSmoothText()
          Returns the boolean flag that decides whether to apply smoothing functions to text.
 void setDrawSmoothImage(boolean drawSmoothImage)
          Sets the boolean flag that decides whether to apply smoothing functions to Images.
 void setDrawSmoothLineArt(boolean drawSmoothLineArt)
          Sets the boolean flag that decides whether to apply smoothing functions to LineArt.
 void setDrawSmoothText(boolean drawSmoothText)
          Sets the boolean flag that decides whether to apply smoothing functions to text.
 void setThresholdResolutionForSmoothing(int thresholdResolutionForSmoothing)
          Sets the Threshold Resolution For Smoothing (in dpi).
 Document toImage(Document inPdfDoc, ToImageOptionsSpec toImageOptionsSpec)
          This method converts a PDF document to Image.
 java.util.List toImage2(Document inPdfDoc, ToImageOptionsSpec toImageOptionsSpec)
          This method converts a PDF document to a List of Image documents.
 Document toPS(Document inPdfDoc, PSLevel psLevel)
          This method converts the given Flat PDF file to PostScript format using the version indicated by psLevel.
 Document toPS2(Document inPdfDoc, ToPSOptionsSpec toPSOptionsSpec)
          This method converts the given Flat PDF file to PostScript format using the options specified in the option spec.
 java.util.List toSWF(Document inPdfDoc, ToSWFOptionsSpec toSWFOptionsSpec)
          This method converts a PDF document to a List of SWF documents using the options specified in the option spec
 void unzipArchive(Document inZipDoc, java.lang.String destDir)
          This method unzips the archive to the destination directory.
 

Field Detail

THRESHOLD_RESOLUTION_FOR_SMOOTHING

static final java.lang.String THRESHOLD_RESOLUTION_FOR_SMOOTHING
Parameters used in deciding whether to do smoothing or not for text,lineArt and image. ThresholdResolutionForSmoothing : Threshold resolution (in dpi) below which we apply the combination of the following smoothing flags DrawSmoothText : This flag decides whether to apply smoothing functions to text or not DrawSmoothLineArt : This flag decides whether to apply smoothing functions to LineArt or not DrawSmoothImage : This flag decides whether to apply smoothing to image functions to images or not.

See Also:
Constant Field Values

DRAW_SMOOTH_TEXT

static final java.lang.String DRAW_SMOOTH_TEXT
See Also:
Constant Field Values

DRAW_SMOOTH_LINE_ART

static final java.lang.String DRAW_SMOOTH_LINE_ART
See Also:
Constant Field Values

DRAW_SMOOTH_IMAGE

static final java.lang.String DRAW_SMOOTH_IMAGE
See Also:
Constant Field Values
Method Detail

getThresholdResolutionForSmoothing

int getThresholdResolutionForSmoothing()
Returns the Threshold Resolution For Smoothing (in dpi). Below this resolution the smoothing functions are applied.

Returns:
int

setThresholdResolutionForSmoothing

void setThresholdResolutionForSmoothing(int thresholdResolutionForSmoothing)
Sets the Threshold Resolution For Smoothing (in dpi). This parameter would only be used in toImage and toImage2 APIs. Below this resolution the smoothing functions are applied.

Parameters:
thresholdResolutionForSmoothing -

isDrawSmoothText

boolean isDrawSmoothText()
Returns the boolean flag that decides whether to apply smoothing functions to text. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Returns:
boolean

setDrawSmoothText

void setDrawSmoothText(boolean drawSmoothText)
Sets the boolean flag that decides whether to apply smoothing functions to text. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Parameters:
drawSmoothText -

isDrawSmoothLineArt

boolean isDrawSmoothLineArt()
Returns the boolean flag that decides whether to apply smoothing functions to LineArt. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Returns:
boolean

setDrawSmoothLineArt

void setDrawSmoothLineArt(boolean drawSmoothLineArt)
Sets the boolean flag that decides whether to apply smoothing functions to LineArt. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Parameters:
drawSmoothText -

isDrawSmoothImage

boolean isDrawSmoothImage()
Returns the boolean flag that decides whether to apply smoothing functions to Images. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Returns:
boolean

setDrawSmoothImage

void setDrawSmoothImage(boolean drawSmoothImage)
Sets the boolean flag that decides whether to apply smoothing functions to Images. This parameter would only be used in toImage and toImage2 APIs. This flag would be used only when the resolution set in toImageOptionsSpec is less than the Threshold Resolution For Smoothing (in dpi).

Parameters:
drawSmoothText -

toPS

Document toPS(Document inPdfDoc,
              PSLevel psLevel)
              throws ConvertPdfException
This method converts the given Flat PDF file to PostScript format using the version indicated by psLevel.

Parameters:
sourcePdf - Document object for the source PDF
psLevel - The version level for the output PostScript
Returns:
Document The document object for the output PostScript file.
Throws:
ConvertPdfException

toPS2

Document toPS2(Document inPdfDoc,
               ToPSOptionsSpec toPSOptionsSpec)
               throws ConvertPdfException
This method converts the given Flat PDF file to PostScript format using the options specified in the option spec. A call to ConvertPdf BMC is made.

Parameters:
sourcePdf - Document object for the source PDF
toPSOptionsSpec - ToPSOptionsSpec option spec
Returns:
Document The document object for the output PostScript file.
Throws:
ConvertPdfException

toImage

Document toImage(Document inPdfDoc,
                 ToImageOptionsSpec toImageOptionsSpec)
                 throws ConvertPdfException
This method converts a PDF document to Image. The resulting image files are zipped and returned as a Document. Supported image formats are JPEG, JPEG2K, PNG and TIFF.

Parameters:
inPdfDoc - - PDF document to be converted to Image
toImageOptionsSpec - - This bean holds various preferences for image conversions.

Following preferences can be set. Default values will be used incase no value is supplied.
The following table lists the valid values:

ConversionFormat JPEG, JPEG2K, PNG, TIFF (Required)
GrayScale Compression Minimum,Low,Medium,High,Maximum,Lossless,LZW,Zip,None
Color Compression Minimum,Low,Medium,High,Maximum,Lossless,LZW,Zip,None
JPEG Format Baseline Standard,Baseline Optimized,3 scans,4 scans,5 scans
RGB Policy Embed Profile,Off
CMYK Policy Embed Profile,Off
GrayScale Policy Embed Profile, Off
Color Space RGB,CMYK,Gray Scale
Resolution 72,96,150,300,600,1200,2400
Tile Size  
Interlace None,Adam7
PNG Filter None,Sub,Up,Average,Paeth,Adaptive
Monochrome None,CCIT G3,CCITT G4,LZW,Zip
Multipage Tiff True, False
Returns:
Document The document object for the output Image files archived in ZIP format.
Throws:
ConvertPdfException

toImage2

java.util.List toImage2(Document inPdfDoc,
                        ToImageOptionsSpec toImageOptionsSpec)
                        throws ConvertPdfException
This method converts a PDF document to a List of Image documents. Supported image formats are JPEG, JPEG2K, PNG and TIFF.

Parameters:
inPdfDoc - - PDF document to be converted to Image
toImageOptionsSpec - - This bean holds various preferences for image conversions.

Following preferences can be set. Default values will be used incase no value is supplied.
The following table lists the valid values:

ConversionFormat JPEG, JPEG2K, PNG, TIFF (Required)
GrayScale Compression Minimum,Low,Medium,High,Maximum,Lossless,LZW,Zip,None
Color Compression Minimum,Low,Medium,High,Maximum,Lossless,LZW,Zip,None
JPEG Format Baseline Standard,Baseline Optimized,3 scans,4 scans,5 scans
RGB Policy Embed Profile,Off
CMYK Policy Embed Profile,Off
GrayScale Policy Embed Profile, Off
Color Space RGB,CMYK,Gray Scale
Resolution 72,96,150,300,600,1200,2400
Tile Size  
Interlace None,Adam7
PNG Filter None,Sub,Up,Average,Paeth,Adaptive
Monochrome None,CCIT G3,CCITT G4,LZW,Zip
Multipage Tiff True, False
Returns:
List, the list of image Document objects.
Throws:
ConvertPdfException

unzipArchive

void unzipArchive(Document inZipDoc,
                  java.lang.String destDir)
                  throws ConvertPdfException
This method unzips the archive to the destination directory.

Parameters:
inZipDoc - - Document object constructed from the Zip file
destDir - - Output Directory
Throws:
ConvertPdfException

toSWF

java.util.List toSWF(Document inPdfDoc,
                     ToSWFOptionsSpec toSWFOptionsSpec)
                     throws ConvertPdfException
This method converts a PDF document to a List of SWF documents using the options specified in the option spec

Parameters:
inPdfDoc - Document object for the source PDF
toSWFOptionsSpec - ToSWFOptionsSpec option spec
Returns:
List, the list of SWF Document objects.
Throws:
ConvertPdfException