Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

249 lines
14 KiB

  1. // AppManDispatch.idl : IDL source for AppManDispatch.dll
  2. //
  3. // This file will be processed by the MIDL tool to
  4. // produce the type library (AppManDispatch.tlb) and marshalling code.
  5. import "oaidl.idl";
  6. import "ocidl.idl";
  7. [
  8. object,
  9. uuid(E5065E80-0228-4469-9FAD-DE1F352A27FE),
  10. dual,
  11. helpstring("IAppEntry Interface"),
  12. pointer_default(unique)
  13. ]
  14. interface IAppEntry : IDispatch
  15. {
  16. [propget, id(1), helpstring("property Guid")] HRESULT Guid([out, retval] BSTR *pVal);
  17. [propput, id(1), helpstring("property Guid")] HRESULT Guid([in] BSTR newVal);
  18. [propget, id(2), helpstring("property CompanyName")] HRESULT CompanyName([out, retval] BSTR *pVal);
  19. [propput, id(2), helpstring("property CompanyName")] HRESULT CompanyName([in] BSTR newVal);
  20. [propget, id(3), helpstring("property Signature")] HRESULT Signature([out, retval] BSTR *pVal);
  21. [propput, id(3), helpstring("property Signature")] HRESULT Signature([in] BSTR newVal);
  22. [propget, id(4), helpstring("property VersionString")] HRESULT VersionString([out, retval] BSTR *pVal);
  23. [propput, id(4), helpstring("property VersionString")] HRESULT VersionString([in] BSTR newVal);
  24. [propget, id(5), helpstring("property LastUsedDate")] HRESULT LastUsedDate([out, retval] DATE *pVal);
  25. [propget, id(6), helpstring("property InstallDate")] HRESULT InstallDate([out, retval] DATE *pVal);
  26. [propget, id(7), helpstring("property Category")] HRESULT Category([out, retval] long *pVal);
  27. [propput, id(7), helpstring("property Category")] HRESULT Category([in] long newVal);
  28. [propget, id(8), helpstring("property State")] HRESULT State([out, retval] long *pVal);
  29. [propput, id(8), helpstring("property State")] HRESULT State([in] long newVal);
  30. [propget, id(9), helpstring("property SetupRootPath")] HRESULT SetupRootPath([out, retval] BSTR *pVal);
  31. [propget, id(10), helpstring("property ApplicationRootPath")] HRESULT ApplicationRootPath([out, retval] BSTR *pVal);
  32. [propput, id(10), helpstring("property ApplicationRootPath")] HRESULT ApplicationRootPath([in] BSTR newVal);
  33. [propget, id(11), helpstring("property EstimatedInstallKilobytes")] HRESULT EstimatedInstallKilobytes([out, retval] long *pVal);
  34. [propput, id(11), helpstring("property EstimatedInstallKilobytes")] HRESULT EstimatedInstallKilobytes([in] long newVal);
  35. [propget, id(12), helpstring("property ExecuteCmdLine")] HRESULT ExecuteCmdLine([out, retval] BSTR *pVal);
  36. [propput, id(12), helpstring("property ExecuteCmdLine")] HRESULT ExecuteCmdLine([in] BSTR newVal);
  37. [propget, id(13), helpstring("property DefaultSetupExeCmdLine")] HRESULT DefaultSetupExeCmdLine([out, retval] BSTR *pVal);
  38. [propput, id(13), helpstring("property DefaultSetupExeCmdLine")] HRESULT DefaultSetupExeCmdLine([in] BSTR newVal);
  39. [propget, id(14), helpstring("property DownsizeCmdLine")] HRESULT DownsizeCmdLine([out, retval] BSTR *pVal);
  40. [propput, id(14), helpstring("property DownsizeCmdLine")] HRESULT DownsizeCmdLine([in] BSTR newVal);
  41. [propget, id(15), helpstring("property ReInstallCmdLine")] HRESULT ReInstallCmdLine([out, retval] BSTR *pVal);
  42. [propput, id(15), helpstring("property ReInstallCmdLine")] HRESULT ReInstallCmdLine([in] BSTR newVal);
  43. [propget, id(16), helpstring("property UnInstallCmdLine")] HRESULT UnInstallCmdLine([out, retval] BSTR *pVal);
  44. [propput, id(16), helpstring("property UnInstallCmdLine")] HRESULT UnInstallCmdLine([in] BSTR newVal);
  45. [propget, id(17), helpstring("property SelfTestCmdLine")] HRESULT SelfTestCmdLine([out, retval] BSTR *pVal);
  46. [propput, id(17), helpstring("property SelfTestCmdLine")] HRESULT SelfTestCmdLine([in] BSTR newVal);
  47. [propget, id(18), helpstring("property TitleURL")] HRESULT TitleURL([out, retval] BSTR *pVal);
  48. [propput, id(18), helpstring("property TitleURL")] HRESULT TitleURL([in] BSTR newVal);
  49. [propget, id(19), helpstring("property DeveloperURL")] HRESULT DeveloperURL([out, retval] BSTR *pVal);
  50. [propput, id(19), helpstring("property DeveloperURL")] HRESULT DeveloperURL([in] BSTR newVal);
  51. [propget, id(20), helpstring("property PublisherURL")] HRESULT PublisherURL([out, retval] BSTR *pVal);
  52. [propput, id(20), helpstring("property PublisherURL")] HRESULT PublisherURL([in] BSTR newVal);
  53. [propget, id(21), helpstring("property XMLInfoFile")] HRESULT XMLInfoFile([out, retval] BSTR *pVal);
  54. [propput, id(21), helpstring("property XMLInfoFile")] HRESULT XMLInfoFile([in] BSTR newVal);
  55. [id(22), helpstring("method Clear")] HRESULT Clear();
  56. [id(23), helpstring("method InitializeInstall")] HRESULT InitializeInstall();
  57. [id(24), helpstring("method FinalizeInstall")] HRESULT FinalizeInstall();
  58. [id(25), helpstring("method InitializeDownsize")] HRESULT InitializeDownsize();
  59. [id(26), helpstring("method FinalizeDownsize")] HRESULT FinalizeDownsize();
  60. [id(27), helpstring("method InitializeReInstall")] HRESULT InitializeReInstall();
  61. [id(28), helpstring("method FinalizeReInstall")] HRESULT FinalizeReInstall();
  62. [id(29), helpstring("method InitializeUnInstall")] HRESULT InitializeUnInstall();
  63. [id(30), helpstring("method FinalizeUnInstall")] HRESULT FinalizeUnInstall();
  64. [id(31), helpstring("method InitializeSelfTest")] HRESULT InitializeSelfTest();
  65. [id(32), helpstring("method FinalizeSelfTest")] HRESULT FinalizeSelfTest();
  66. [id(33), helpstring("method Abort")] HRESULT Abort();
  67. [id(34), helpstring("method Run")] HRESULT Run([in] long lRunFlags, [in] BSTR newVal);
  68. [id(35), helpstring("method AddAssociation")] HRESULT AddAssociation([in] long AssociationType, [in] IAppEntry * lpAppEntry);
  69. [id(36), helpstring("method RemoveAssociation")] HRESULT RemoveAssociation([in] long lAssociationType, [in] IAppEntry * lpAppEntry);
  70. [id(37), helpstring("method EnumAssociationTypes")] HRESULT EnumAssociationTypes([in] long lAssociationIndex, [out, retval] long * lpAssociationType);
  71. [id(38), helpstring("method EnumAssociationObjects")] HRESULT EnumAssociationObjects([in] long lAssociationIndex, [in] IAppEntry * lpAppEntry);
  72. [id(39), helpstring("method GetTemporarySpace")] HRESULT GetTemporarySpace([in] long lKilobytesRequired, [out, retval] BSTR * strRootPath);
  73. [id(40), helpstring("method RemoveTemporarySpace")] HRESULT RemoveTemporarySpace([in] BSTR strRootPath);
  74. [id(41), helpstring("method EnumTemporarySpacePaths")] HRESULT EnumTemporarySpacePaths([in] long lTempSpaceIndex, [out, retval] BSTR * strRootPath);
  75. [id(42), helpstring("method EnumTemporarySpaceAllocations")] HRESULT EnumTemporarySpaceAllocations([in] long lTempSpaceIndex, [out, retval] long * lTempSpaceKilobytes);
  76. [propget, id(43), helpstring("obsolete property, does nothing")] HRESULT RemovableKilobytes([out, retval] long *pVal);
  77. [propput, id(43), helpstring("obsolete property, does nothing")] HRESULT RemovableKilobytes([in] long newVal);
  78. [propget, id(44), helpstring("obsolete property, does nothing")] HRESULT NonRemovableKilobytes([out, retval] long *pVal);
  79. [propput, id(44), helpstring("obsolete property, does nothing")] HRESULT NonRemovableKilobytes([in] long newVal);
  80. };
  81. [
  82. object,
  83. uuid(8D051768-5370-40AF-B149-2B265F39CCA2),
  84. dual,
  85. helpstring("IAppManager Interface"),
  86. pointer_default(unique)
  87. ]
  88. interface IAppManager : IDispatch
  89. {
  90. [propget, id(1), helpstring("property AdvancedMode")] HRESULT AdvancedMode([out, retval] long *pVal);
  91. [propget, id(2), helpstring("property MaximumAvailableKilobytes")] HRESULT MaximumAvailableKilobytes(long lSpaceCategory, [out, retval] long *pVal);
  92. [propget, id(3), helpstring("property OptimalAvailableKilobytes")] HRESULT OptimalAvailableKilobytes(long lSpaceCategory, [out, retval] long *pVal);
  93. [propget, id(4), helpstring("property ApplicationCount")] HRESULT ApplicationCount([out, retval] long *pVal);
  94. [id(5), helpstring("method CreateApplicationEntry")] HRESULT CreateApplicationEntry([out, retval] IAppEntry ** lppAppEntry);
  95. [id(6), helpstring("method GetApplicationInfo")] HRESULT GetApplicationInfo([in] IAppEntry * lpAppEntry);
  96. [id(7), helpstring("method EnumApplications")] HRESULT EnumApplications([in] long lApplicationIndex, [in] IAppEntry * lpAppEntry);
  97. [id(8), helpstring("method EnumDeviceAvailableKilobytes")] HRESULT EnumDeviceAvailableKilobytes([in] long lDeviceIndex, [out, retval] long * lKilobytes);
  98. [id(9), helpstring("method EnumDeviceRootPaths")] HRESULT EnumDeviceRootPaths([in] long lDeviceIndex, [out, retval] BSTR * strRootPath);
  99. [id(10), helpstring("method EnumDeviceExclusionMask")] HRESULT EnumDeviceExclusionMask([in] long lDeviceIndex, [out, retval] long * lExclusionMask);
  100. };
  101. [
  102. uuid(132ACE4B-3FDF-4B61-A22B-38049687F970),
  103. version(1.0),
  104. helpstring("AppManDispatch 1.0 Type Library")
  105. ]
  106. library APPMANDISPATCHLib
  107. {
  108. importlib("stdole2.tlb");
  109. //
  110. // Defines used with GetProperty(APP_PROPERTY_STATE, ...)
  111. //
  112. typedef enum CONST_APP_STATES
  113. {
  114. APP_STATE_INSTALLING = 0x00000001,
  115. APP_STATE_READY = 0x00000002,
  116. APP_STATE_DOWNSIZING = 0x00000004,
  117. APP_STATE_DOWNSIZED = 0x00000008,
  118. APP_STATE_REINSTALLING = 0x00000010,
  119. APP_STATE_UNINSTALLING = 0x00000020,
  120. APP_STATE_UNINSTALLED = 0x00000040,
  121. APP_STATE_SELFTESTING = 0x00000080,
  122. APP_STATE_UNSTABLE = 0x00000100,
  123. APP_STATE_MASK = 0x000001ff
  124. } APPSTATES;
  125. //
  126. // Defines used with Set/GetProperty(APP_PROPERTY_CATEGORY, ...)
  127. //
  128. typedef enum CONST_APP_CATEGORIES
  129. {
  130. APP_CATEGORY_NONE = 0x00000000,
  131. APP_CATEGORY_ENTERTAINMENT = 0x00000001,
  132. APP_CATEGORY_PRODUCTIVITY = 0x00000002,
  133. APP_CATEGORY_PUBLISHING = 0x00000004,
  134. APP_CATEGORY_SCIENTIFIC = 0x00000008,
  135. APP_CATEGORY_AUTHORING = 0x00000010,
  136. APP_CATEGORY_MEDICAL = 0x00000020,
  137. APP_CATEGORY_BUSINESS = 0x00000040,
  138. APP_CATEGORY_FINANCIAL = 0x00000080,
  139. APP_CATEGORY_EDUCATIONAL = 0x00000100,
  140. APP_CATEGORY_REFERENCE = 0x00000200,
  141. APP_CATEGORY_WEB = 0x00000400,
  142. APP_CATEGORY_DEVELOPMENTTOOL = 0x00000800,
  143. APP_CATEGORY_MULTIMEDIA = 0x00001000,
  144. APP_CATEGORY_VIRUSCLEANER = 0x00002000,
  145. APP_CATEGORY_CONNECTIVITY = 0x00004000,
  146. APP_CATEGORY_MISC = 0x00008000,
  147. APP_CATEGORY_DEMO = 0x01000000,
  148. APP_CATEGORY_PATCH = 0x02000000,
  149. APP_CATEGORY_DATA = 0x04000000,
  150. APP_CATEGORY_ALL = 0x0700ffff
  151. } APP_CATEGORIES;
  152. //
  153. // Association defines
  154. //
  155. typedef enum CONST_APP_ASSOCIATION_TYPES
  156. {
  157. APP_ASSOCIATION_CHILD = 0x40000000,
  158. APP_ASSOCIATION_PARENT = 0x80000000,
  159. APP_ASSOCIATION_INHERITBOTHPATHS = 0x00000001,
  160. APP_ASSOCIATION_INHERITAPPROOTPATH = 0x00000002,
  161. APP_ASSOCIATION_INHERITSETUPROOTPATH = 0x00000004
  162. } APP_ASSOCIATION_TYPES;
  163. //
  164. // Some misc defines
  165. //
  166. typedef enum CONST_MISC_DEFINES
  167. {
  168. MAX_COMPANYNAME_CHARCOUNT = 64,
  169. MAX_SIGNATURE_CHARCOUNT = 64,
  170. MAX_VERSIONSTRING_CHARCOUNT = 16,
  171. MAX_CMDLINE_CHARCOUNT = 255,
  172. MAX_PATH_CHARCOUNT = 255
  173. } MISC_DEFINES;
  174. //
  175. // Error Codes
  176. //
  177. typedef enum CONST_ERROR_CODES
  178. {
  179. APPMAN_E_NOTINITIALIZED = 0x85670001,
  180. APPMAN_E_INVALIDPROPERTYSIZE = 0x85670005,
  181. APPMAN_E_INVALIDDATA = 0x85670006,
  182. APPMAN_E_INVALIDPROPERTY = 0x85670007,
  183. APPMAN_E_READONLYPROPERTY = 0x85670008,
  184. APPMAN_E_PROPERTYNOTSET = 0x85670009,
  185. APPMAN_E_OVERFLOW = 0x8567000a,
  186. APPMAN_E_INVALIDPROPERTYVALUE = 0x8567000c,
  187. APPMAN_E_ACTIONINPROGRESS = 0x8567000d,
  188. APPMAN_E_ACTIONNOTINITIALIZED = 0x8567000e,
  189. APPMAN_E_REQUIREDPROPERTIESMISSING = 0x8567000f,
  190. APPMAN_E_APPLICATIONALREADYEXISTS = 0x85670010,
  191. APPMAN_E_APPLICATIONALREADYLOCKED = 0x85670011,
  192. APPMAN_E_NODISKSPACEAVAILABLE = 0x85670012,
  193. APPMAN_E_UNKNOWNAPPLICATION = 0x85670014,
  194. APPMAN_E_INVALIDPARAMETERS = 0x85670015,
  195. APPMAN_E_OBJECTLOCKED = 0x85670017,
  196. APPMAN_E_INVALIDINDEX = 0x85670018,
  197. APPMAN_E_REGISTRYCORRUPT = 0x85670019,
  198. APPMAN_E_CANNOTASSOCIATE = 0x8567001a,
  199. APPMAN_E_INVALIDASSOCIATION = 0x8567001b,
  200. APPMAN_E_ALREADYASSOCIATED = 0x8567001c,
  201. APPMAN_E_APPLICATIONREQUIRED = 0x8567001d,
  202. APPMAN_E_INVALIDEXECUTECMDLINE = 0x8567001e,
  203. APPMAN_E_INVALIDDOWNSIZECMDLINE = 0x8567001f,
  204. APPMAN_E_INVALIDREINSTALLCMDLINE = 0x85670020,
  205. APPMAN_E_INVALIDUNINSTALLCMDLINE = 0x85670021,
  206. APPMAN_E_INVALIDSELFTESTCMDLINE = 0x85670022,
  207. APPMAN_E_PARENTAPPNOTREADY = 0x85670023,
  208. APPMAN_E_INVALIDSTATE = 0x85670024,
  209. APPMAN_E_INVALIDROOTPATH = 0x85670025,
  210. APPMAN_E_CACHEOVERRUN = 0x85670026,
  211. APPMAN_E_REINSTALLDX = 0x85670028,
  212. APPMAN_E_APPNOTEXECUTABLE = 0x85670029
  213. } ERROR_CODES;
  214. [
  215. uuid(9D4BD41C-508B-4D49-894E-F09242B68AF8),
  216. helpstring("AppEntry Class")
  217. ]
  218. coclass AppEntry
  219. {
  220. [default] interface IAppEntry;
  221. };
  222. [
  223. uuid(09A0E8F4-3C5D-4EA3-B56A-4E0731EE861A),
  224. helpstring("AppManager Class")
  225. ]
  226. coclass AppManager
  227. {
  228. [default] interface IAppManager;
  229. };
  230. };