InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IConversionMgr.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Robin Briggs
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //
23 // Purpose of Interface:
24 // Manages file format conversions between different versions of plug-ins.
25 //
26 //========================================================================================
27 
28 #ifndef __IConversionMgr__
29 #define __IConversionMgr__
30 
31 // ----- Interfaces -----
32 
33 #include "IPMUnknown.h"
34 
35 // ----- Includes -----
36 
37 #include "FormatNumber.h"
38 #include "K2Vector.h"
39 
40 // ----- ID.h files -----
41 
42 #include "ShuksanID.h"
43 
44 
45 class FormatID;
46 class VersionID;
47 class IDataBase;
48 class IPMStream;
49 class IContentMgr;
51 
58 class IConversionMgr : public IPMUnknown
59 {
60 public:
61  enum { kDefaultIID = IID_ICONVERSIONMGR };
62 
65  {
74  };
75 
82  virtual ConversionStatus GetStatus(IContentMgr *contentMgr) = 0;
83 
88  virtual void GetRemovedPlugins(K2Vector<PluginID> &list) = 0;
89 
94  virtual void GetIgnoredPlugins(K2Vector<PluginID> &list) = 0;
95 
99  virtual void ConvertDocument(IDataBase *dbToConvert) = 0;
100 
105  virtual void Open(IContentMgr *contentMgr) = 0;
106 
109  virtual void Close() = 0;
110 
122  virtual ClassID ConvertClass(ClassID inClass, ImplementationID parentContext, IPMStream *inStream, IPMStream *outStream, int32 length) = 0;
123 
133  virtual bool16 CopyClassData(ClassID inClass, const VersionID &version, bool16 isEmbedded, uint32 inLength, IPMStream *inStream, IPMStream *outStream) = 0;
134 
146  virtual ImplementationID ConvertTag(ImplementationID inTag, ClassID parentContext, IPMStream *inStream, IPMStream *outStream, int32 length) = 0;
147 
156  virtual bool16 CopyTagData(ImplementationID inImpl, const VersionID &version, uint32 inLength, IPMStream *inStream, IPMStream *outStream) = 0;
157 
162  virtual IDataBase *GetConvertingDataBase() = 0;
163 
169  virtual UID GetConvertingUID() = 0;
170 
174  virtual int32 CountConversionFailures() = 0;
175 
180  virtual PluginID GetNthFailedConversion(int32 n) = 0;
181 
187 
193 
199  virtual bool16 GetSourcePluginFormatNumber(PluginID plugin, FormatID &format) const = 0;
200 
208  virtual bool16 ReadSourceData(UID uid, ImplementationID implID, const FormatID &format, IPMStream *outStream) = 0;
209 
215 
221 
227  virtual bool16 GetTargetPluginFormatNumber(PluginID plugin, FormatID &format) = 0;
228 
235  virtual void RemoveClass(ClassID clsID) = 0;
236 
243  virtual void RemoveImplementation(ImplementationID implID) = 0;
244 
245 #if defined(DEBUG)
246 
247  virtual void OverrideRunningVersion(const VersionID& substitueVersion) = 0;
248 #endif
249 };
250 
251 
252 #endif // __IConversionMgr__