Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages | Examples

DWFToolkit::DWFPackageVersionExtension Class Reference
[DWF Package API]

#include "dwf/package/writer/PackageVersionExtension.h"

Inheritance diagram for DWFToolkit::DWFPackageVersionExtension:

Inheritance graph
[legend]
List of all members.

Detailed Description

This is the plug-in interface for the DWFPackageWriter.
Since:
7.0.1.

This interface is intended to be used to modify the publish-time behavior of the DWFPackageWriter; specifically to capture and implement version-specific differences in the DWF. As a general rule, version variations may be created to support a new feature or introduce new functionality. Eventually, these might be removed from the format entirely but the ability to produce the package variations must continue to exist.

The interface works by mimicking some of the DWFPackageWriter interface. The writer, when used with an extension, will first make the matching call on the extension. This methods must return a boolean value that communicates the continuation intent back to the writer. If true, the writer will continue to process it's own call path after returning from the extension. If false, the writer will return immediately from it's own call path after returning from the extension.

Definition at line 74 of file PackageVersionExtension.h.

Public Member Functions

virtual _DWFTK_API ~DWFPackageVersionExtension () throw ()
virtual _DWFTK_API unsigned
short 
major ()=0 throw ()
virtual _DWFTK_API unsigned
short 
minor ()=0 throw ()
virtual _DWFTK_API bool addSection (DWFSection *pSection, DWFInterface *pInterface=NULL)=0 throw ( DWFException )
virtual _DWFTK_API bool addGlobalSection (DWFGlobalSection *pSection)=0 throw ( DWFException )
virtual _DWFTK_API bool write (const DWFString &zSourceProductVendor=L"", const DWFString &zSourceProductName=L"", const DWFString &zSourceProductVersion=L"", const DWFString &zDWFProductVendor=L"", const DWFString &zDWFProductVersion=L"", DWFZipFileDescriptor::teFileMode eCompressionMode=DWFZipFileDescriptor::eZipSmallest)=0 throw ( DWFException )
virtual _DWFTK_API void prewriteManifest (DWFPackageWriter &rPackageWriter, DWFPackageFileDescriptor &rPackageDescriptor, DWFXMLSerializer &rXMLSerializer, const DWFString &zPackagePassword)=0 throw ( DWFException )
virtual _DWFTK_API void postwriteManifest (DWFPackageWriter &rPackageWriter, DWFPackageFileDescriptor &rPackageDescriptor, DWFXMLSerializer &rXMLSerializer, const DWFString &zPackagePassword)=0 throw ( DWFException )
virtual _DWFTK_API void postwriteSections (DWFPackageWriter &rPackageWriter, DWFPackageFileDescriptor &rPackageDescriptor, DWFXMLSerializer &rXMLSerializer, const DWFString &zPackagePassword)=0 throw ( DWFException )

Protected Member Functions

_DWFTK_API DWFPackageVersionExtension () throw ()


Constructor & Destructor Documentation

virtual _DWFTK_API DWFToolkit::DWFPackageVersionExtension::~DWFPackageVersionExtension  )  throw () [inline, virtual]
 

Destructor

Exceptions:
None 

Definition at line 85 of file PackageVersionExtension.h.

_DWFTK_API DWFToolkit::DWFPackageVersionExtension::DWFPackageVersionExtension  )  throw () [inline, protected]
 

Constructor

Exceptions:
None 

Definition at line 198 of file PackageVersionExtension.h.


Member Function Documentation

virtual _DWFTK_API bool DWFToolkit::DWFPackageVersionExtension::addGlobalSection DWFGlobalSection pSection  )  throw ( DWFException ) [pure virtual]
 

Adds a type global section to the DWF package.

Parameters:
pSection The global section to publish into the package. Ownership of this section pointer will be claimed automatically. This means that, left as is, the pointer will be deleted once the package is published. In order to prevent this, the caller can explicitly reclaim ownership of the section by calling DWFSection::own().
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API bool DWFToolkit::DWFPackageVersionExtension::addSection DWFSection pSection,
DWFInterface pInterface = NULL
throw ( DWFException ) [pure virtual]
 

Adds a section to the DWF package.

Parameters:
pSection The section to publish into the package. Ownership of this section pointer will be claimed automatically. This means that, left as is, the pointer will be deleted once the package is published. In order to prevent this, the caller can explicitly reclaim ownership of the section by calling DWFSection::own().
pInterface This object should be provided if pSection is a custom type that should be declared in the manifest (it will be ignored for known types.) Note that the DWF Specification dictates that at least one interface be declared in the manifest. If none exist, an exception will be thrown at write time. This pointer will be deleted with the DWFCORE_FREE_OBJECT macro.
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API unsigned short DWFToolkit::DWFPackageVersionExtension::major  )  throw () [pure virtual]
 

Returns the DWF File Format major version for this extension.

Returns:
The integer value of the major format version.
Exceptions:
None 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API unsigned short DWFToolkit::DWFPackageVersionExtension::minor  )  throw () [pure virtual]
 

Returns the DWF File Format minor version for this extension.

Returns:
The integer value of the minor format version.
Exceptions:
None 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API void DWFToolkit::DWFPackageVersionExtension::postwriteManifest DWFPackageWriter rPackageWriter,
DWFPackageFileDescriptor rPackageDescriptor,
DWFXMLSerializer rXMLSerializer,
const DWFString zPackagePassword
throw ( DWFException ) [pure virtual]
 

Hook provided after the manifest.xml document is created and published.

Parameters:
rPackageWriter The object managing the creation of the DWF package file.
rPackageDescriptor The file descriptor of the DWF package file being created.
rXMLSerializer The object being used to create the XML data.
zPackagePassword If the entire package is being password protected or if this extension is adding a password protected file, this password will be used.
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API void DWFToolkit::DWFPackageVersionExtension::postwriteSections DWFPackageWriter rPackageWriter,
DWFPackageFileDescriptor rPackageDescriptor,
DWFXMLSerializer rXMLSerializer,
const DWFString zPackagePassword
throw ( DWFException ) [pure virtual]
 

Hook provided after all sections have been published.

Parameters:
rPackageWriter The object managing the creation of the DWF package file.
rPackageDescriptor The file descriptor of the DWF package file being created.
rXMLSerializer The object being used to create the XML data.
zPackagePassword If the entire package is being password protected or if this extension is adding a password protected file, this password will be used.
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API void DWFToolkit::DWFPackageVersionExtension::prewriteManifest DWFPackageWriter rPackageWriter,
DWFPackageFileDescriptor rPackageDescriptor,
DWFXMLSerializer rXMLSerializer,
const DWFString zPackagePassword
throw ( DWFException ) [pure virtual]
 

Hook provided just before the manifest.xml document is created and published.

Parameters:
rPackageWriter The object managing the creation of the DWF package file.
rPackageDescriptor The file descriptor of the DWF package file being created.
rXMLSerializer The object being used to create the XML data.
zPackagePassword If the entire package is being password protected or if this extension is adding a password protected file, this password will be used.
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.

virtual _DWFTK_API bool DWFToolkit::DWFPackageVersionExtension::write const DWFString zSourceProductVendor = L"",
const DWFString zSourceProductName = L"",
const DWFString zSourceProductVersion = L"",
const DWFString zDWFProductVendor = L"",
const DWFString zDWFProductVersion = L"",
DWFZipFileDescriptor::teFileMode  eCompressionMode = DWFZipFileDescriptor::eZipSmallest
throw ( DWFException ) [pure virtual]
 

Writes out the DWF package.

Any sections and other objects owned by the writer and/or internal manifest will be deleted at the completion of this method. Be sure to claim ownership of any such objects that are necessary to survive after this call.

This method exposes the standard DWF package properties directly. It is highly recommended that at DWF publishers set these correctly with as much detail as possible.

Setting standard DWF package properties:

                Autodesk DWF Writer is a printer driver DLL that is used to generate DWF packages
                through the Windows printing system, it is a component that another application
                would use (indirectly) to publish the DWF.  The following is an example of how
                it might populate these properties when printing from Microsoft Word:
       
                zSourceProductVendor    = L"Microsoft Corporation"          <--- from Word 2003
                zSourceProductName      = L"Microsoft Office 2003"          <--- from Word 2003
                zSourceProductVersion   = L"11.0.5604"                      <--- from Word 2003
                zDWFProductVendor       = L"Autodesk, Inc."                 <--- from DWF Writer 2
                zDWFProductVersion      = L"2.0.4.0"                        <--- from DWF Writer 2

Parameters:
zSourceProductVendor A standard property detailing the vendor of the software that the produced the original content and used the DWF product in order to produce the DWF package.
zSourceProductName A standard property detailing the name of the software that the produced the original content and used the DWF product in order to produce the DWF package.
zSourceProductVersion A standard property detailing the version of the software that the produced the original content and used the DWF product in order to produce the DWF package.
zDWFProductVendor A standard property that details the vendor of the software component that was used by the source product to publish the DWF package.
zDWFProductVersion A standard property that details the version of the software component that was used by the source product to publish the DWF package.
eCompressionMode An enumeration that adjusts the zip library compression options.
Exceptions:
DWFException 

Implemented in DWFToolkit::DWFPackageVersionTypeInfoExtension.


The documentation for this class was generated from the following file:
Generated on Tue May 17 12:39:10 2005 for Autodesk DWF Toolkit by  doxygen 1.4.1