PDFOptimizer Class Documentation
classPDFOptimizer : SystemIDisposableNamespace:Datalogics::PDFL
- Inherits from:
SystemIDisposable
Detailed Description
Implementation of the PDF Optimizer function.
Use the PDFOptimizer object to accumulate options for the Optimization, and to Optimize documents.
Referenced by
Constructor & Destructor Documentation
PDFOptimizer
PDFOptimizer(PDFOptimizerrhs, InternalConstructsignifier)Parameters
rhs: PDFOptimizersignifier: InternalConstruct
PDFOptimizer
PDFOptimizer()Construct a CPDFOptimizer, with default Options.
~PDFOptimizer
~PDFOptimizer()Property Documentation
MajorVersion
shortMajorVersion[get, set]MinorVersion
shortMinorVersion[get, set]ObjectCompression
ObjectCompressionTypeObjectCompression[get, set]Member Function Documentation
ConstructorRetrieve
static PDFOptimizerConstructorRetrieve(System.IntPtrignored)Parameters
ignored: System.IntPtr
Returns:
PDFOptimizerDispose
voidDispose()Returns:
voidDisposeChildren
voidDisposeChildren()Returns:
voidGetCompressionQuality
CompressQualityGetCompressionQuality(CompressImageTypetype)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to query.
Returns:
The compression quality level for the specified color model.Get the value of the Compression Quality for a given color model.
GetMaxResolution
intGetMaxResolution(CompressImageTypetype)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to query.
Returns:
The maximum resolution in DPI above which images will be downsampled.Get the value of the Max DPI for a given color model.
GetOption
boolGetOption(OptimizerOptionoption)Parameters
option: OptimizerOptionThe optimization option to query.
Returns:
true if the option is enabled, false if it is disabled.Get the value of a single Optimizer Option.
GetRecompressionType
CompressionTypeGetRecompressionType(CompressImageTypetype)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to query.
Returns:
The compression type that will be applied to images of the specified color model.Get the value of the Recompression Type for a given color model.
GetResampleToResolution
intGetResampleToResolution(CompressImageTypetype)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to query.
Returns:
The target resolution in DPI to which images will be downsampled.Get the value of the Resample To DPI for a given color model.
Optimize
voidOptimize(Documentdocument, CDotNetStreamFiledest)Parameters
document: DocumentThe document to optimize.
dest: CDotNetStreamFileThe stream file handle to write the optimized document to.
Returns:
voidPerform the Optimization of a single document, saving the result to a stream.
Optimize
voidOptimize(Documentdocument, CDotNetStreamFiledest, ProgressMonitorprogressMonitor, CancelProccancelProc)Parameters
document: DocumentThe document to optimize.
dest: CDotNetStreamFileThe stream file handle to write the optimized document to.
progressMonitor: ProgressMonitorAn optional progress monitor callback, or NULL.
cancelProc: CancelProcAn optional cancellation callback, or NULL.
Returns:
voidPerform the Optimization of a single document, saving the result to a stream.
Optimize
voidOptimize(Documentdoc, System.IO.Streamstream)Parameters
doc: Documentstream: System.IO.Stream
Returns:
voidOptimize
voidOptimize(Documentdoc, System.IO.Streamstream, ProgressMonitorprogressMonitor, CancelProccancelProc)Parameters
doc: Documentstream: System.IO.StreamprogressMonitor: ProgressMonitorcancelProc: CancelProc
Returns:
voidOptimize
voidOptimize(Documentdocument, stringnewPath)Parameters
document: DocumentThe document to optimize.
newPath: stringThe file system path where the optimized document will be saved.
Returns:
voidPerform the Optimization of a single document, saving the result in a new file.
Optimize
voidOptimize(Documentdocument, stringnewPath, ProgressMonitorprogressMonitor, CancelProccancelProc)Parameters
document: DocumentThe document to optimize.
newPath: stringThe file system path where the optimized document will be saved.
progressMonitor: ProgressMonitorAn optional progress monitor callback, or NULL.
cancelProc: CancelProcAn optional cancellation callback, or NULL.
Returns:
voidPerform the Optimization of a single document, saving the result in a new file.
SetCompressionQuality
voidSetCompressionQuality(CompressImageTypetype, CompressQualityvalue)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to set.
value: CompressQualityThe compression quality level to apply.
Returns:
voidSet the value for the Compression Quality for a given color model. Any image that recompressed, regardless of the reason, will use this Quality for the Quality value of the specific compression type.
SetMaxResolution
voidSetMaxResolution(CompressImageTypetype, intvalue)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to set.
value: intThe maximum resolution in DPI.
Returns:
voidSet the value for the Max DPI for a given color model. Any image above this resolution will be down sampled, if the Downsampling option is true for this color model.
SetOption
voidSetOption(OptimizerOptionoption, boolvalue)Parameters
option: OptimizerOptionThe optimization option to set.
value: booltrue to enable the option, false to disable it.
Returns:
voidSet the value of a single Optimizer option.
SetRecompressionType
voidSetRecompressionType(CompressImageTypetype, CompressionTypevalue)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to set.
value: CompressionTypeThe compression type to apply.
Returns:
voidSet the value for the recompression Type for a given color model. Any image that is downsampled will be compressed using this method, if the Downsampling option is true for this color model. Any image that is not downsampled, will be converted to this compression type, if it is not already compressed in this type, and the Recompression option for this color model is true.
SetResampleToResolution
voidSetResampleToResolution(CompressImageTypetype, intvalue)Parameters
type: CompressImageTypeThe image color type (Color, Gray, or BW) to set.
value: intThe target resolution in DPI.
Returns:
voidSet the value for the Resample To DPI for a given color model. Any image will be downsampled to this resolution, if the Downsampling option is true for this color model.