|
pdfmm 0.9.20
|
#include <PdfOutputDevice.h>
Public Member Functions | |
| virtual | ~PdfOutputDevice () |
| void | Write (const std::string_view &view) |
| void | Put (char ch) |
| size_t | Read (char *buffer, size_t len) |
| void | Seek (size_t offset) |
| size_t | GetLength () const |
| size_t | Tell () const |
| void | Flush () |
This class provides an output device which operates either on a file or on a buffer in memory. Additionally it can count the bytes written to the device.
This class is suitable for inheritance to provide output devices of your own for pdfmm. Just override the required virtual methods.
|
virtual |
Destruct the PdfOutputDevice object and close any open files.
| void PdfOutputDevice::Flush | ( | ) |
Flush the output files buffer to disk if this devices operates on a disk.
|
inline |
The number of bytes written to this object.
| void PdfOutputDevice::Put | ( | char | ch | ) |
Write the character in the device
| ch | the character to wrte |
| size_t PdfOutputDevice::Read | ( | char * | buffer, |
| size_t | len | ||
| ) |
Read data from the device
| buffer | a pointer to the data buffer |
| len | length of the output buffer |
| void PdfOutputDevice::Seek | ( | size_t | offset | ) |
Seek the device to the position offset from the beginning
| offset | from the beginning of the file |
|
inline |
Get the current offset from the beginning of the file.
| void PdfOutputDevice::Write | ( | const std::string_view & | view | ) |
Write the view to the PdfOutputDevice
| view | the view to be written |