include/MiKTeX206-packagemanager.idl

00001 /* mpm.idl:                                                     -*- IDL -*-
00002 
00003    Copyright (C) 2006-2007 Christian Schenk
00004 
00005    This file is part of MiKTeX Package Manager.
00006 
00007    MiKTeX Package Manager is free software; you can redistribute it
00008    and/or modify it under the terms of the GNU General Public License
00009    as published by the Free Software Foundation; either version 2, or
00010    (at your option) any later version.
00011    
00012    MiKTeX Package Manager is distributed in the hope that it will be
00013    useful, but WITHOUT ANY WARRANTY; without even the implied warranty
00014    of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015    GNU General Public License for more details.
00016    
00017    You should have received a copy of the GNU General Public License
00018    along with MiKTeX Package Manager; if not, write to the Free
00019    Software Foundation, 59 Temple Place - Suite 330, Boston, MA
00020    02111-1307, USA. */
00021 
00022 import "oaidl.idl";
00023 import "ocidl.idl";
00024 
00025 import "miktexidl.idl";
00026 
00027 /* _________________________________________________________________________
00028    
00029    MD5
00030    _________________________________________________________________________ */
00031 
00035 typedef [uuid(F92D6E8F-22CC-4585-8309-58440C5A0DFB)] struct MD5
00036 {
00038   BYTE bits[16];
00039 } MD5;
00040 
00041 
00042 /* _________________________________________________________________________
00043    
00044    PackageInfo
00045    _________________________________________________________________________ */
00046 
00048 typedef [uuid(22A5E6E6-04B3-4540-A122-6A612210F52E)] struct PackageInfo
00049 {
00051   BSTR deploymentName;
00053   BSTR displayName;
00055   BSTR title;
00057   BSTR version;
00059   BSTR description;
00061   BSTR creator;
00063   DOUBLE sizeRunFiles;
00065   DOUBLE sizeDocFiles;
00067   DOUBLE sizeSourceFiles;
00069   LONG numRunFiles;
00071   LONG numDocFiles;
00073   LONG numSourceFiles;
00075   DATE timePackaged;
00077   DATE timeInstalled;
00079   LONG archiveFileSize;
00081   MD5 digest;
00083   VARIANT_BOOL isInstalled;
00084 } PackageInfo;
00085 
00086 /* _________________________________________________________________________
00087    
00088    IPackageInstallerCallback
00089    _________________________________________________________________________ */
00090 
00095 [
00096   object,
00097   uuid(4B081787-2C08-4AFD-80E1-B4B3E23324B4),
00098   nonextensible,
00099   helpstring("IPackageInstallerCallback Interface"),
00100   pointer_default(unique)
00101 ]
00102 interface IPackageInstallerCallback : IUnknown
00103 {
00106   [
00107     helpstring("method ReportLine")
00108   ]
00109   HRESULT ReportLine ([in] BSTR line);
00110 
00114   [
00115     helpstring("method OnRetryableError")
00116   ]
00117   HRESULT
00118   OnRetryableError ([in] BSTR                   message,
00119                     [out,retval] VARIANT_BOOL * doContinue);
00120 
00124   [
00125     helpstring("method OnProgress")
00126   ]
00127   HRESULT
00128   OnProgress ([in] LONG nf, [out,retval] VARIANT_BOOL * doContinue);
00129 };
00130 
00131 /* _________________________________________________________________________
00132    
00133    IPackageInstaller
00134    _________________________________________________________________________ */
00135 
00137 [
00138   object,
00139   uuid(74C7EE83-4851-4766-B471-9CF29E7C2DA3),
00140   dual,
00141   nonextensible,
00142   helpstring("IPackageInstaller Interface"),
00143   pointer_default(unique)
00144 ]
00145 interface IPackageInstaller : IDispatch
00146 {
00151   [
00152     id(1),
00153     helpstring("method Add")
00154   ]
00155   HRESULT
00156   Add ([in] BSTR packageName, [in] VARIANT_BOOL toBeInstalled);
00157 
00161   [
00162     id(2),
00163     helpstring("method SetCallback")
00164   ]
00165   HRESULT
00166   SetCallback ([in] IUnknown * callback);
00167 
00169   [
00170     id(3),
00171     helpstring("method InstallRemove")
00172   ]
00173   HRESULT
00174   InstallRemove ();
00175 
00178   [
00179     id(4),
00180     helpstring("method GetLastError")
00181   ]
00182   HRESULT
00183   GetErrorInfo ([out,retval] ErrorInfo * errorInfo);
00184 
00186   [
00187     id(5),
00188     helpstring("method UpdateDb")
00189   ]
00190   HRESULT
00191   UpdateDb ();
00192 
00195   [
00196     id(6),
00197     helpstring("method SetRepository")
00198   ]
00199   HRESULT
00200   SetRepository ([in] BSTR repository);
00201 };
00202 
00203 /* _________________________________________________________________________
00204    
00205    IPackageManager
00206    _________________________________________________________________________ */
00207 
00209 [
00210   object,
00211   uuid(C6A0E0A9-532D-46DF-8969-0E0A17539FC9),
00212   dual,
00213   nonextensible,
00214   helpstring("IPackageManager Interface"),
00215   pointer_default(unique)
00216 ]
00217 interface IPackageManager : IDispatch
00218 {
00221   [
00222     id(1),
00223     helpstring("method CreateInstaller")
00224   ]
00225   HRESULT
00226   CreateInstaller ([out,retval] IPackageInstaller ** installer);
00227 
00231   [
00232     id(2),
00233     helpstring("method GetPackageInfo")
00234   ]
00235   HRESULT
00236   GetPackageInfo ([in] BSTR                     packageName,
00237                   [out,retval] PackageInfo *    packageInfo);
00238 };
00239 
00240 /* _________________________________________________________________________
00241    
00242    MiKTeXPackageManager2_6
00243    _________________________________________________________________________ */
00244 
00246 [
00247   uuid(42542DAE-9AAF-41A0-A2FC-7F3CEEA9A5CB),
00248   version(1.0),
00249   helpstring("MiKTeX 2.6 Package Manager")
00250 ]
00251 library MiKTeXPackageManager2_6
00252 {
00253   importlib("stdole2.tlb");
00254 
00256   [
00257     uuid(E4EC6D80-9E3A-47B7-ADA7-C0621C298527),
00258     helpstring("MiKTeX 2.6 Package Manager")
00259   ]
00260   coclass PackageManager2_6
00261   {
00262     [default] interface IPackageManager;
00263   };
00264 
00265   interface IPackageInstaller;
00266   interface IPackageInstallerCallback;
00267 };

Generated on Tue May 29 21:24:53 2007 for MiKTeX by  doxygen 1.5.1-p1