![]() |
Mako 8.3.0 API
MakoCore SDK API Documentation
|
A simple class representing a mutable array of other PDF objects. More...
#include <jawsmako/pdfobjects.h>
Public Member Functions | |
| virtual | ~IPDFArray () |
| virtual uint32 | getSize () const =0 |
| Get the current size of the array. | |
| virtual IPDFObjectPtr | get (uint32 index) const =0 |
| Get the object stored at the given index. An exception will be thrown if the index is out of range. | |
| virtual ePDFObjectType | getTypeAtIndex (uint32 index) const =0 |
| Get the type of the object stored at the given index. An exception will be thrown if the index is out of range. | |
| virtual void | put (uint32 index, const IPDFObjectPtr &value)=0 |
| Store the given object in the array at the given index, replacing the currently stored object. If the index is outside the array, it will be resized to suit. An exception will be thrown if the index is out of range. | |
| virtual void | insert (uint32 index, const IPDFObjectPtr &value)=0 |
| Insert the given object in the array at the given index, moving the following objects forward to make room. An exception will be thrown if the index is out of range. | |
| virtual void | remove (uint32 index)=0 |
| Remove the object at the given index from the array, decreasing the size of the array by 1. An exception will be thrown if the index is out of range. | |
| virtual void | append (const IPDFObjectPtr &value)=0 |
| Convenience member to append an object to the end of the array. | |
| virtual void | copy (uint32 destIndex, const IPDFArrayPtr &sourceArray, uint32 sourceIndex)=0 |
| Copy (but not clone) an entry from another array into an existing position in this array, replacing any currently stored object. Usually more efficient for bulk operations. | |
| virtual bool | getNumbers (CDoubleVect &numbers)=0 |
| If the array consists entirely of numbers, retrieve those numbers. | |
| virtual bool | getBox (FBox &box)=0 |
| If the array consists of four numbers, retrieve those numbers as a box (left, bottom, right, top) | |
| virtual int32 | getInteger (uint32 index) const =0 |
| Convenience member to obtain an integer from the array at the given index. An exception will be thrown if the index is out of range or the object is not an integer. | |
| virtual bool | containsCompositeObject (const IPDFObjectPtr &object) const =0 |
| Recursively check to see if the array contains the given composite object (That is, a dictionary, stream, or array). | |
| Public Member Functions inherited from JawsMako::IPDFObject | |
| virtual ePDFObjectType | getType () const =0 |
| Get the type of this PDF object. | |
| virtual IPDFObjectPtr | clone () const =0 |
| Create a clone of this PDF object if appropriate. Note that simple immutable objects are not actually cloned and instead the same object is returned. | |
| virtual IPDFObjectPtr | deepClone () const =0 |
| Create a deep clone of this PDF object if appropriate. Note that simple immutable objects are not actually cloned and instead the same object is returned. If the object is composite (an IPDFArray, IPDFDictionary or IPDFStream) then the object will be cloned as well as the constituent objects in a recursive fashion. | |
| virtual bool | getIsExecutable () const =0 |
| Get whether the object is considered executable, such as an executable name, array, or operator. | |
| virtual bool | containsReferences () const =0 |
| Get whether the object contains indirect references to other objects (that is, does the object or any constituent object contain IPDFReference or IPDFFarReference objects). | |
| virtual void | emitPostScriptCode (const IOutputStreamPtr &dest) const =0 |
| Convert the object to PostScript code and write to the given stream. Only allowed for objects that are representable in PostScript. | |
| virtual bool | getNumber (double &number) const =0 |
| If the object is a number (a real or integer) obtain that number. | |
| virtual bool | getNumber (float &number) const =0 |
| If the object is a number (a real or integer) within the range of a 32-bit float, obtain that number. If the object is an integer, this will fail if the integer cannot be represented exactly in a single precision float. | |
| virtual bool | getNumber (int32 &number) const =0 |
| If the object is an integer (a integral real or integer) within the range of a 32-bit integer, obtain that number. | |
| virtual bool | getString (RawString &string) const =0 |
| If the object is a string or a name, retrieve the raw string data. | |
| 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. | |
| Public Member Functions inherited from JawsMako::IHashable | |
| virtual | ~IHashable () |
| virtual uint64 | hash () const |
| Obtain a 64-bit hash of the receiving object. | |
| virtual void | updateHash (uint64 &hash) const =0 |
| Update the given hash to include the receiver. | |
Static Public Member Functions | |
| static JAWSMAKO_API IPDFArrayPtr | create (uint32 size=0, bool executable=false) |
| Create a new PDF array of the given initial size. | |
| static JAWSMAKO_API IPDFArrayPtr | create (const CPDFObjectVect &objects, bool executable=false) |
| Create a new PDF array from a vector of IPDFObjects. | |
| static JAWSMAKO_API IPDFArrayPtr | createFromNumbers (const CDoubleVect &numbers) |
| Create from a vector of numbers. | |
| static JAWSMAKO_API IPDFArrayPtr | createFromFloatNumbers (const CFloatVect &numbers) |
| Create from a vector of numbers as floats. | |
| static JAWSMAKO_API IPDFArrayPtr | createFromNumbersArray (const double *numbers, uint32 numNumbers) |
| Create from an array of numbers. | |
| static JAWSMAKO_API IPDFArrayPtr | createFromNames (IEDLClassFactory *pFactory, const CRawStringVect &nameStrings) |
| Create an array of names from a vector of strings. | |
| static JAWSMAKO_API IPDFArrayPtr | createFromFBox (const FBox &box) |
| Create from an FBox. | |
| Static Public Member Functions inherited from JawsMako::IPDFObject | |
| static JAWSMAKO_API IPDFObjectPtr | createNumber (double number) |
| If the given number is an integer, create an IPDFInteger, otherwise create an IPDFReal. | |
Additional Inherited Members | |
| Protected Member Functions inherited from IRCObject | |
| virtual | ~IRCObject () |
| Virtual destructor. | |
A simple class representing a mutable array of other PDF objects.
|
inlinevirtual |
|
pure virtual |
Convenience member to append an object to the end of the array.
| value | The object to append. |
|
pure virtual |
Recursively check to see if the array contains the given composite object (That is, a dictionary, stream, or array).
| object | The object to search for. |
|
pure virtual |
Copy (but not clone) an entry from another array into an existing position in this array, replacing any currently stored object. Usually more efficient for bulk operations.
| destIndex | The destination index to store the object. |
| sourceArray | The array object from which to copy. |
| sourceIndex | The index of the entry in sourceArray to copy. |
|
static |
Create a new PDF array from a vector of IPDFObjects.
| objects | The objects to assign to the array. |
| executable | If this array should be marked executable (that is, a PDF/PS procedure). |
|
static |
Create a new PDF array of the given initial size.
| size | The initial size of the array. It will be populated with IPDFNull objects. |
| executable | If this array should be marked executable (that is, a PDF/PS procedure). |
|
static |
|
static |
Create from a vector of numbers as floats.
| numbers | The numbers to assign to the array. |
|
static |
|
static |
Create from a vector of numbers.
| numbers | The numbers to assign to the array. |
|
static |
Create from an array of numbers.
| numbers | The numbers to assign to the array. |
| numNumbers | The number of numbers in the array. Integers will be created where possible. |
|
pure virtual |
Get the object stored at the given index. An exception will be thrown if the index is out of range.
| index | The index of the desired object. |
|
pure virtual |
If the array consists of four numbers, retrieve those numbers as a box (left, bottom, right, top)
| box | The FBox to receive the numbers. |
Convenience member to obtain an integer from the array at the given index. An exception will be thrown if the index is out of range or the object is not an integer.
| index | The index of the object to query. |
|
pure virtual |
If the array consists entirely of numbers, retrieve those numbers.
| numbers | A reference to a vector to receive the numbers. |
|
pure virtual |
Get the current size of the array.
|
pure virtual |
Get the type of the object stored at the given index. An exception will be thrown if the index is out of range.
| index | The index of the desired object. |
|
pure virtual |
Insert the given object in the array at the given index, moving the following objects forward to make room. An exception will be thrown if the index is out of range.
| index | The index at which to store the object. |
| value | The object to insert. |
|
pure virtual |
Store the given object in the array at the given index, replacing the currently stored object. If the index is outside the array, it will be resized to suit. An exception will be thrown if the index is out of range.
| index | The index at which to store the object. |
| value | The object to store. |
|
pure virtual |
Remove the object at the given index from the array, decreasing the size of the array by 1. An exception will be thrown if the index is out of range.
| index | The index of the object to remove. |