Mako 7.5.0 API
Loading...
Searching...
No Matches
JawsMako::IPDFPageExtractor Class Referenceabstract

An instance of the JawsMako PDFPageExtractor class. More...

#include <pdfpage.h>

Inheritance diagram for JawsMako::IPDFPageExtractor:

Public Member Functions

virtual uint32 getNumPages ()=0
 Return the number of pages in the document.
 
virtual void extract (const IOutputStreamPtr &outputStream, uint32 pageIndex, uint32 numPages)=0
 Extract a range of pages into a given output stream.
 
virtual void extractFrom (const IOutputStreamPtr &outputStream, uint32 pageIndex)=0
 Extract a range of pages from a given index into a given output stream.
 
virtual void extractTo (const IOutputStreamPtr &outputStream, uint32 pageIndex)=0
 Extract a range of pages to a given index into a given output stream.
 
- Public Member Functions inherited from IRCObject
virtual void addRef () const =0
 Increases the reference count of the actual object pointed to. This would take place during an assignment or copying.
 
virtual bool decRef () const =0
 Decreases the reference count of the actual object pointed to. When the reference count falls to Zero, it deletes the actual object pointed to.
 
virtual int32 getRefCount () const =0
 Retrieve the current reference count of the actual object pointed to.
 

Static Public Member Functions

static JAWSMAKO_API IPDFPageExtractorPtr create (const IJawsMakoPtr &jawsMako, const IInputStreamPtr &inputStream, const U8String &password=U8String(), uint32 permissions=0, const IProgressMonitorPtr &progressMonitor=IProgressMonitorPtr())
 Create an IPDFPageExtractor interface.
 

Additional Inherited Members

- Protected Member Functions inherited from IRCObject
virtual ~IRCObject ()
 Virtual destructor.
 

Detailed Description

An instance of the JawsMako PDFPageExtractor class.

Member Function Documentation

◆ create()

static JAWSMAKO_API IPDFPageExtractorPtr JawsMako::IPDFPageExtractor::create ( const IJawsMakoPtr & jawsMako,
const IInputStreamPtr & inputStream,
const U8String & password = U8String(),
uint32 permissions = 0,
const IProgressMonitorPtr & progressMonitor = IProgressMonitorPtr() )
static

Create an IPDFPageExtractor interface.

The IPDFPageExtractor interface allows extraction of pages from a PDF.

Parameters
jawsMakoThe IJawsMako object.
inputStreamThe input PDF stream.
passwordThe password to use. Assumed to be UTF-8.
permissionsThe allowed permissions.

If allowed permissions is set to IDOMStandardPDFSecurityInfo::eEverythingAllowed then no checking for assembly permissions will be performed.

Otherwise, the parameter is the or'd combination of IDOMStandardPDFSecurity::ePermissionsFlags that is checked against the permissions defined in the input PDF. If an operation corresponds to a flag set in the parameter, then output will be allowed to continue. Otherwise, an IError exception with the error code JM_ERR_ASSEMBLY_WRITE_FORBIDDEN will be thrown.

If the source has no permissions information the output will proceed regardless.

The default is 0.

Parameters
progressMonitorA smart pointer to an IProgressMonitor object which can be NULL if no such object was passed in.
Returns
IPDFPageExtractorPtr A smart pointer to the IPDFPageExtractor object.

◆ extract()

virtual void JawsMako::IPDFPageExtractor::extract ( const IOutputStreamPtr & outputStream,
uint32 pageIndex,
uint32 numPages )
pure virtual

Extract a range of pages into a given output stream.

Pages are numbered starting at zero. An exception will be thrown if an invalid page range is specified.

Parameters
outputStreamThe output stream.
pageIndexThe index of the first page to extract.
numPagesThe number of pages to extract.

◆ extractFrom()

virtual void JawsMako::IPDFPageExtractor::extractFrom ( const IOutputStreamPtr & outputStream,
uint32 pageIndex )
pure virtual

Extract a range of pages from a given index into a given output stream.

A convenience function. Equivalent to extract(pageIndex, getNumPages());

Pages are numbered starting at zero. An exception will be thrown if an invalid page range is specified.

Parameters
outputStreamThe output stream.
pageIndexThe index of the first page to extract.

◆ extractTo()

virtual void JawsMako::IPDFPageExtractor::extractTo ( const IOutputStreamPtr & outputStream,
uint32 pageIndex )
pure virtual

Extract a range of pages to a given index into a given output stream.

A convenience function. Equivalent to extract(0, pageIndex + 1);

Pages are numbered starting at zero. An exception will be thrown if an invalid page range is specified.

Parameters
outputStreamThe output stream.
pageIndexThe index of the page to extract to.

◆ getNumPages()

virtual uint32 JawsMako::IPDFPageExtractor::getNumPages ( )
pure virtual

Return the number of pages in the document.

Returns
uint32 The number of pages in the document.

The documentation for this class was generated from the following file: