All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
pdftron::PDF::ExternalAnnotManager Class Reference

#include <ExternalAnnotManager.h>

Public Types

enum  Mode { e_user_only, e_admin_undo_others, e_admin_undo_own }
 

Public Member Functions

 ExternalAnnotManager ()
 
 ExternalAnnotManager (const ExternalAnnotManager &other)
 
 ExternalAnnotManager (TRN_ExternalAnnotManager impl)
 
ExternalAnnotManageroperator= (const ExternalAnnotManager &other)
 
 ~ExternalAnnotManager ()
 
void Destroy ()
 
void MergeXFDF (UString xfdf_content)
 
UString Undo ()
 
UString GetLastXFDF () const
 
UString GetLastJSON () const
 
UString Redo ()
 
UString GetNextRedoInfo ()
 
UString GetNextUndoInfo ()
 
UString TakeSnapshot (UString payload)
 

Public Attributes

TRN_ExternalAnnotManager m_impl
 

Detailed Description

The class ExternalAnnotManager. A manager class attached to a PDFView that takes care of annotations from xfdf sources

ExternalAnnotManager instances are created through the PDFView using PDFView.GetExternalAnnotManager()

Definition at line 25 of file ExternalAnnotManager.h.

Member Enumeration Documentation

Enumerator
e_user_only 
e_admin_undo_others 
e_admin_undo_own 

Definition at line 28 of file ExternalAnnotManager.h.

Constructor & Destructor Documentation

pdftron::PDF::ExternalAnnotManager::ExternalAnnotManager ( )
pdftron::PDF::ExternalAnnotManager::ExternalAnnotManager ( const ExternalAnnotManager other)
pdftron::PDF::ExternalAnnotManager::ExternalAnnotManager ( TRN_ExternalAnnotManager  impl)
pdftron::PDF::ExternalAnnotManager::~ExternalAnnotManager ( )

Member Function Documentation

void pdftron::PDF::ExternalAnnotManager::Destroy ( )
UString pdftron::PDF::ExternalAnnotManager::GetLastJSON ( ) const

Retrieve the last JSON command string produced by the last call to either Undo, Redo, or TakeSnapshot.

Returns
a json command string.
UString pdftron::PDF::ExternalAnnotManager::GetLastXFDF ( ) const

Retrieve the last XFDF command string produced by the last call to either Undo, Redo, or TakeSnapshot.

Returns
an xfdf command string.
UString pdftron::PDF::ExternalAnnotManager::GetNextRedoInfo ( )

Returns any meta-data associated with the next state in the redo chain.

Returns
a string consisting of the payload that was provided when TakeSnapshot was called.
UString pdftron::PDF::ExternalAnnotManager::GetNextUndoInfo ( )

Returns any meta-data associated with the next state in the undo chain.

Returns
a string consisting of the payload that was provided when TakeSnapshot was called.
void pdftron::PDF::ExternalAnnotManager::MergeXFDF ( UString  xfdf_content)

Merge an xfdf string into the current document. This Xfdf can be in normal Adobe format, or it contain xfdf commands like add, delete, and modify.

Parameters
xfdf_content– xfdf string with content to be added to the document.
ExternalAnnotManager& pdftron::PDF::ExternalAnnotManager::operator= ( const ExternalAnnotManager other)
UString pdftron::PDF::ExternalAnnotManager::Redo ( )

Perform the conversion. Will throw an exception on failure. Does nothing if the conversion is already complete. Use GetConversionStatus() to check if there is remaining content to be converted.

Returns
a string consisting of the payload that was provided when TakeSnapshot was called. If that payload was in JSON format, then it will have added field "xfdf", containing the xfdf commands representing the changes made by this call (if any).
UString pdftron::PDF::ExternalAnnotManager::TakeSnapshot ( UString  payload)

Take an undo snapshot, returning the xfdf command string representing any change in state since the last snapshot.

Parameters
payload– a string that will be returned when Undo or Redo are called such that the transition marked by this snapshot is reversed..
Returns
an xfdf string.
UString pdftron::PDF::ExternalAnnotManager::Undo ( )

Perform the conversion. Will throw an exception on failure.

Returns
a string consisting of the payload that was provided when TakeSnapshot was called. If that payload was in JSON format, then it will have added field "xfdf", containing the xfdf commands representing the changes made by this call (if any).

Member Data Documentation

TRN_ExternalAnnotManager pdftron::PDF::ExternalAnnotManager::m_impl

Definition at line 103 of file ExternalAnnotManager.h.


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