InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IImportProviderUtils Class Referenceabstract

#include <IImportProviderUtils.h>

Inheritance diagram for IImportProviderUtils:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IIMPORTPROVIDERUTILS }
 

Public Member Functions

virtual IImportProviderQueryImportProviderFor (const ExternalPMFlavor fromWhichFlavor, const PMFlavor toWhichInternalFlavor)=0
 
virtual bool16 DoesProviderSupportExternalFlavor (IImportProvider *provider, const ExternalPMFlavor flavor)=0
 
virtual IImportProviderQueryImportProviderForFileType (const SysOSType fileType)=0
 
virtual bool16 DoesProviderSupportFileType (IImportProvider *provider, const SysOSType fileType)=0
 
virtual IExportProviderQueryExportProviderFor (const PMFlavor fromWhichInternalFlavor, const ExternalPMFlavor toWhichFlavor)=0
 
virtual bool16 DoesProviderSupportExternalFlavor (IExportProvider *provider, const ExternalPMFlavor flavor)=0
 
virtual uint32 GetFlavorsForExport (const PMFlavor fromWhichInternalFlavor, ExternalPMFlavorList &toWhichFlavors)=0
 
virtual uint32 GetFlavorsForImport (const PMFlavor toWhichInternalFlavor, ExternalPMFlavorList &fromWhichFlavors)=0
 
virtual ErrorCode SendImportExportSignal (const ServiceID &service, IDocument *document, const URI &uri, const PMString &formatName, UIFlags &uiFlags, bool8 bIsStandAlone=kTrue, ExportSessionToken *sessionToken=nil)=0
 
virtual ErrorCode SendImportExportSignal (const ServiceID &service, IDocument *document, const IDFile &sysFile, const PMString &formatName, UIFlags &uiFlags, bool8 bIsStandAlone=kTrue, ExportSessionToken *sessionToken=nil)=0
 
virtual ErrorCode SendPlaceReplaceSignal (const ServiceID &service, IPlaceBehavior *source, IPlaceBehavior *target, const UIDList &result)=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Utility interface for import and export providers. Providers are used to cnvert between internal and external data/file formats.

See Also
IImportProvider, IExportProvider

Member Function Documentation

virtual bool16 IImportProviderUtils::DoesProviderSupportExternalFlavor (IImportProviderprovider,
const ExternalPMFlavor flavor 
)
pure virtual

Can a provider support conversion from a specific external flavor.

Parameters
providerIN the provider
flavorIN the external flavor
Returns
true if the provider can perform a conversion
virtual bool16 IImportProviderUtils::DoesProviderSupportExternalFlavor (IExportProviderprovider,
const ExternalPMFlavor flavor 
)
pure virtual

Can a provider support conversion to a specific external flavor.

Parameters
providerIN the provider
flavorIN the external flavor
Returns
true if the provider can perform a conversion
virtual bool16 IImportProviderUtils::DoesProviderSupportFileType (IImportProviderprovider,
const SysOSType fileType 
)
pure virtual

Can a provider support conversion from a specific file type.

Parameters
providerIN the provider
fileTypeIN a file type
Returns
true if the provider can perform a conversion
virtual uint32 IImportProviderUtils::GetFlavorsForExport (const PMFlavor fromWhichInternalFlavor,
ExternalPMFlavorListtoWhichFlavors 
)
pure virtual

Compute the list of external flavors that a given internal flavor can be converted to via exporters

Parameters
fromWhichInternalFlavorIN the internal data format
toWhichFlavorsOUT the list of flavors the data could be converted to
Returns
the number of possible conversions
virtual uint32 IImportProviderUtils::GetFlavorsForImport (const PMFlavor toWhichInternalFlavor,
ExternalPMFlavorListfromWhichFlavors 
)
pure virtual

Compute the list of external flavors that a given internal flavor can be produced from via importers

Parameters
toWhichInternalFlavorIN the internal data format
fromWhichFlavorsIN the list of flavors the data could be produced from
Returns
the number of possible conversions
virtual IExportProvider* IImportProviderUtils::QueryExportProviderFor (const PMFlavor fromWhichInternalFlavor,
const ExternalPMFlavor toWhichFlavor 
)
pure virtual

Query for export provider to handle a data conversion.

Parameters
fromWhichInternalFlavorIN internal data format the data is to be converted from
toWhichFlavorIN external data format the data is to be converted to
Returns
an export provider capable of performing the conversion, or nil.
virtual IImportProvider* IImportProviderUtils::QueryImportProviderFor (const ExternalPMFlavor fromWhichFlavor,
const PMFlavor toWhichInternalFlavor 
)
pure virtual

Query for import provider to handle a data conversion.

Parameters
fromWhichFlavorIN external data format the data is to be converted from
toWhichInternalFlavorIN internal data format the data is to be converted to
Returns
an import provider capable of performing the conversion, or nil.
virtual IImportProvider* IImportProviderUtils::QueryImportProviderForFileType (const SysOSType fileType)
pure virtual

Query for import provider to handle a file conversion.

Parameters
fileTypeIN the type of the file
Returns
an import provider capable of performing the conversion, or nil.
virtual ErrorCode IImportProviderUtils::SendImportExportSignal (const ServiceIDservice,
IDocumentdocument,
const URIuri,
const PMStringformatName,
UIFlags & uiFlags,
bool8 bIsStandAlone = kTrue,
ExportSessionToken * sessionToken = nil 
)
pure virtual

Send an import or export signal to responders

Parameters
serviceIN is the signal's service ID
documentIN is the target document
uriIN is the resource/file being im/exported.
formatNameIN is the format being im/exported
uiFlagsIN/OUT are the ui flags, which could be changed by a responder
bIsStandAloneIN determines if this asset is a standalone asset or part of a group of assets
sessionTokenIN/OUT an ExportSessionToken passed by reference. Updated by each call.
Returns
global error code if set by a responder
virtual ErrorCode IImportProviderUtils::SendImportExportSignal (const ServiceIDservice,
IDocumentdocument,
const IDFilesysFile,
const PMStringformatName,
UIFlags & uiFlags,
bool8 bIsStandAlone = kTrue,
ExportSessionToken * sessionToken = nil 
)
pure virtual

DEPRECATED: Use the version that passes a URI instead of an IDFile. Send an import or export signal to responders

Parameters
serviceIN is the signal's service ID
documentIN is the target document
sysFileIN is the file being im/exported
formatNameIN is the format being im/exported
uiFlagsIN/OUT are the ui flags, which could be changed by a responder
bIsStandAloneIN determines if this asset is a standalone asset or part of a group of assets
sessionTokenIN/OUT an ExportSessionToken passed by reference. Updated by each call.
Returns
global error code if set by a responder
virtual ErrorCode IImportProviderUtils::SendPlaceReplaceSignal (const ServiceIDservice,
IPlaceBehaviorsource,
IPlaceBehaviortarget,
const UIDListresult 
)
pure virtual

Send an place or replace signal to responders

Parameters
serviceIN is the signal's service ID
sourceIN is the source's IPlaceBehavior
targetIN is the target's IPlaceBehavior (may be nil, e.g., for a snippet)
resultIN is the placed items (may be empty, e.g., for before place)
Returns
global error code if set by a responder