250 lines
14 KiB
Plaintext
250 lines
14 KiB
Plaintext
|
// AppManDispatch.idl : IDL source for AppManDispatch.dll
|
||
|
//
|
||
|
|
||
|
// This file will be processed by the MIDL tool to
|
||
|
// produce the type library (AppManDispatch.tlb) and marshalling code.
|
||
|
|
||
|
import "oaidl.idl";
|
||
|
import "ocidl.idl";
|
||
|
[
|
||
|
object,
|
||
|
uuid(E5065E80-0228-4469-9FAD-DE1F352A27FE),
|
||
|
dual,
|
||
|
helpstring("IAppEntry Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IAppEntry : IDispatch
|
||
|
{
|
||
|
[propget, id(1), helpstring("property Guid")] HRESULT Guid([out, retval] BSTR *pVal);
|
||
|
[propput, id(1), helpstring("property Guid")] HRESULT Guid([in] BSTR newVal);
|
||
|
[propget, id(2), helpstring("property CompanyName")] HRESULT CompanyName([out, retval] BSTR *pVal);
|
||
|
[propput, id(2), helpstring("property CompanyName")] HRESULT CompanyName([in] BSTR newVal);
|
||
|
[propget, id(3), helpstring("property Signature")] HRESULT Signature([out, retval] BSTR *pVal);
|
||
|
[propput, id(3), helpstring("property Signature")] HRESULT Signature([in] BSTR newVal);
|
||
|
[propget, id(4), helpstring("property VersionString")] HRESULT VersionString([out, retval] BSTR *pVal);
|
||
|
[propput, id(4), helpstring("property VersionString")] HRESULT VersionString([in] BSTR newVal);
|
||
|
[propget, id(5), helpstring("property LastUsedDate")] HRESULT LastUsedDate([out, retval] DATE *pVal);
|
||
|
[propget, id(6), helpstring("property InstallDate")] HRESULT InstallDate([out, retval] DATE *pVal);
|
||
|
[propget, id(7), helpstring("property Category")] HRESULT Category([out, retval] long *pVal);
|
||
|
[propput, id(7), helpstring("property Category")] HRESULT Category([in] long newVal);
|
||
|
[propget, id(8), helpstring("property State")] HRESULT State([out, retval] long *pVal);
|
||
|
[propput, id(8), helpstring("property State")] HRESULT State([in] long newVal);
|
||
|
[propget, id(9), helpstring("property SetupRootPath")] HRESULT SetupRootPath([out, retval] BSTR *pVal);
|
||
|
[propget, id(10), helpstring("property ApplicationRootPath")] HRESULT ApplicationRootPath([out, retval] BSTR *pVal);
|
||
|
[propput, id(10), helpstring("property ApplicationRootPath")] HRESULT ApplicationRootPath([in] BSTR newVal);
|
||
|
[propget, id(11), helpstring("property EstimatedInstallKilobytes")] HRESULT EstimatedInstallKilobytes([out, retval] long *pVal);
|
||
|
[propput, id(11), helpstring("property EstimatedInstallKilobytes")] HRESULT EstimatedInstallKilobytes([in] long newVal);
|
||
|
[propget, id(12), helpstring("property ExecuteCmdLine")] HRESULT ExecuteCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(12), helpstring("property ExecuteCmdLine")] HRESULT ExecuteCmdLine([in] BSTR newVal);
|
||
|
[propget, id(13), helpstring("property DefaultSetupExeCmdLine")] HRESULT DefaultSetupExeCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(13), helpstring("property DefaultSetupExeCmdLine")] HRESULT DefaultSetupExeCmdLine([in] BSTR newVal);
|
||
|
[propget, id(14), helpstring("property DownsizeCmdLine")] HRESULT DownsizeCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(14), helpstring("property DownsizeCmdLine")] HRESULT DownsizeCmdLine([in] BSTR newVal);
|
||
|
[propget, id(15), helpstring("property ReInstallCmdLine")] HRESULT ReInstallCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(15), helpstring("property ReInstallCmdLine")] HRESULT ReInstallCmdLine([in] BSTR newVal);
|
||
|
[propget, id(16), helpstring("property UnInstallCmdLine")] HRESULT UnInstallCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(16), helpstring("property UnInstallCmdLine")] HRESULT UnInstallCmdLine([in] BSTR newVal);
|
||
|
[propget, id(17), helpstring("property SelfTestCmdLine")] HRESULT SelfTestCmdLine([out, retval] BSTR *pVal);
|
||
|
[propput, id(17), helpstring("property SelfTestCmdLine")] HRESULT SelfTestCmdLine([in] BSTR newVal);
|
||
|
[propget, id(18), helpstring("property TitleURL")] HRESULT TitleURL([out, retval] BSTR *pVal);
|
||
|
[propput, id(18), helpstring("property TitleURL")] HRESULT TitleURL([in] BSTR newVal);
|
||
|
[propget, id(19), helpstring("property DeveloperURL")] HRESULT DeveloperURL([out, retval] BSTR *pVal);
|
||
|
[propput, id(19), helpstring("property DeveloperURL")] HRESULT DeveloperURL([in] BSTR newVal);
|
||
|
[propget, id(20), helpstring("property PublisherURL")] HRESULT PublisherURL([out, retval] BSTR *pVal);
|
||
|
[propput, id(20), helpstring("property PublisherURL")] HRESULT PublisherURL([in] BSTR newVal);
|
||
|
[propget, id(21), helpstring("property XMLInfoFile")] HRESULT XMLInfoFile([out, retval] BSTR *pVal);
|
||
|
[propput, id(21), helpstring("property XMLInfoFile")] HRESULT XMLInfoFile([in] BSTR newVal);
|
||
|
[id(22), helpstring("method Clear")] HRESULT Clear();
|
||
|
[id(23), helpstring("method InitializeInstall")] HRESULT InitializeInstall();
|
||
|
[id(24), helpstring("method FinalizeInstall")] HRESULT FinalizeInstall();
|
||
|
[id(25), helpstring("method InitializeDownsize")] HRESULT InitializeDownsize();
|
||
|
[id(26), helpstring("method FinalizeDownsize")] HRESULT FinalizeDownsize();
|
||
|
[id(27), helpstring("method InitializeReInstall")] HRESULT InitializeReInstall();
|
||
|
[id(28), helpstring("method FinalizeReInstall")] HRESULT FinalizeReInstall();
|
||
|
[id(29), helpstring("method InitializeUnInstall")] HRESULT InitializeUnInstall();
|
||
|
[id(30), helpstring("method FinalizeUnInstall")] HRESULT FinalizeUnInstall();
|
||
|
[id(31), helpstring("method InitializeSelfTest")] HRESULT InitializeSelfTest();
|
||
|
[id(32), helpstring("method FinalizeSelfTest")] HRESULT FinalizeSelfTest();
|
||
|
[id(33), helpstring("method Abort")] HRESULT Abort();
|
||
|
[id(34), helpstring("method Run")] HRESULT Run([in] long lRunFlags, [in] BSTR newVal);
|
||
|
[id(35), helpstring("method AddAssociation")] HRESULT AddAssociation([in] long AssociationType, [in] IAppEntry * lpAppEntry);
|
||
|
[id(36), helpstring("method RemoveAssociation")] HRESULT RemoveAssociation([in] long lAssociationType, [in] IAppEntry * lpAppEntry);
|
||
|
[id(37), helpstring("method EnumAssociationTypes")] HRESULT EnumAssociationTypes([in] long lAssociationIndex, [out, retval] long * lpAssociationType);
|
||
|
[id(38), helpstring("method EnumAssociationObjects")] HRESULT EnumAssociationObjects([in] long lAssociationIndex, [in] IAppEntry * lpAppEntry);
|
||
|
[id(39), helpstring("method GetTemporarySpace")] HRESULT GetTemporarySpace([in] long lKilobytesRequired, [out, retval] BSTR * strRootPath);
|
||
|
[id(40), helpstring("method RemoveTemporarySpace")] HRESULT RemoveTemporarySpace([in] BSTR strRootPath);
|
||
|
[id(41), helpstring("method EnumTemporarySpacePaths")] HRESULT EnumTemporarySpacePaths([in] long lTempSpaceIndex, [out, retval] BSTR * strRootPath);
|
||
|
[id(42), helpstring("method EnumTemporarySpaceAllocations")] HRESULT EnumTemporarySpaceAllocations([in] long lTempSpaceIndex, [out, retval] long * lTempSpaceKilobytes);
|
||
|
[propget, id(43), helpstring("obsolete property, does nothing")] HRESULT RemovableKilobytes([out, retval] long *pVal);
|
||
|
[propput, id(43), helpstring("obsolete property, does nothing")] HRESULT RemovableKilobytes([in] long newVal);
|
||
|
[propget, id(44), helpstring("obsolete property, does nothing")] HRESULT NonRemovableKilobytes([out, retval] long *pVal);
|
||
|
[propput, id(44), helpstring("obsolete property, does nothing")] HRESULT NonRemovableKilobytes([in] long newVal);
|
||
|
};
|
||
|
[
|
||
|
object,
|
||
|
uuid(8D051768-5370-40AF-B149-2B265F39CCA2),
|
||
|
dual,
|
||
|
helpstring("IAppManager Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IAppManager : IDispatch
|
||
|
{
|
||
|
[propget, id(1), helpstring("property AdvancedMode")] HRESULT AdvancedMode([out, retval] long *pVal);
|
||
|
[propget, id(2), helpstring("property MaximumAvailableKilobytes")] HRESULT MaximumAvailableKilobytes(long lSpaceCategory, [out, retval] long *pVal);
|
||
|
[propget, id(3), helpstring("property OptimalAvailableKilobytes")] HRESULT OptimalAvailableKilobytes(long lSpaceCategory, [out, retval] long *pVal);
|
||
|
[propget, id(4), helpstring("property ApplicationCount")] HRESULT ApplicationCount([out, retval] long *pVal);
|
||
|
[id(5), helpstring("method CreateApplicationEntry")] HRESULT CreateApplicationEntry([out, retval] IAppEntry ** lppAppEntry);
|
||
|
[id(6), helpstring("method GetApplicationInfo")] HRESULT GetApplicationInfo([in] IAppEntry * lpAppEntry);
|
||
|
[id(7), helpstring("method EnumApplications")] HRESULT EnumApplications([in] long lApplicationIndex, [in] IAppEntry * lpAppEntry);
|
||
|
[id(8), helpstring("method EnumDeviceAvailableKilobytes")] HRESULT EnumDeviceAvailableKilobytes([in] long lDeviceIndex, [out, retval] long * lKilobytes);
|
||
|
[id(9), helpstring("method EnumDeviceRootPaths")] HRESULT EnumDeviceRootPaths([in] long lDeviceIndex, [out, retval] BSTR * strRootPath);
|
||
|
[id(10), helpstring("method EnumDeviceExclusionMask")] HRESULT EnumDeviceExclusionMask([in] long lDeviceIndex, [out, retval] long * lExclusionMask);
|
||
|
};
|
||
|
|
||
|
[
|
||
|
uuid(132ACE4B-3FDF-4B61-A22B-38049687F970),
|
||
|
version(1.0),
|
||
|
helpstring("AppManDispatch 1.0 Type Library")
|
||
|
]
|
||
|
library APPMANDISPATCHLib
|
||
|
{
|
||
|
importlib("stdole2.tlb");
|
||
|
|
||
|
//
|
||
|
// Defines used with GetProperty(APP_PROPERTY_STATE, ...)
|
||
|
//
|
||
|
|
||
|
typedef enum CONST_APP_STATES
|
||
|
{
|
||
|
APP_STATE_INSTALLING = 0x00000001,
|
||
|
APP_STATE_READY = 0x00000002,
|
||
|
APP_STATE_DOWNSIZING = 0x00000004,
|
||
|
APP_STATE_DOWNSIZED = 0x00000008,
|
||
|
APP_STATE_REINSTALLING = 0x00000010,
|
||
|
APP_STATE_UNINSTALLING = 0x00000020,
|
||
|
APP_STATE_UNINSTALLED = 0x00000040,
|
||
|
APP_STATE_SELFTESTING = 0x00000080,
|
||
|
APP_STATE_UNSTABLE = 0x00000100,
|
||
|
APP_STATE_MASK = 0x000001ff
|
||
|
|
||
|
} APPSTATES;
|
||
|
|
||
|
//
|
||
|
// Defines used with Set/GetProperty(APP_PROPERTY_CATEGORY, ...)
|
||
|
//
|
||
|
|
||
|
typedef enum CONST_APP_CATEGORIES
|
||
|
{
|
||
|
APP_CATEGORY_NONE = 0x00000000,
|
||
|
APP_CATEGORY_ENTERTAINMENT = 0x00000001,
|
||
|
APP_CATEGORY_PRODUCTIVITY = 0x00000002,
|
||
|
APP_CATEGORY_PUBLISHING = 0x00000004,
|
||
|
APP_CATEGORY_SCIENTIFIC = 0x00000008,
|
||
|
APP_CATEGORY_AUTHORING = 0x00000010,
|
||
|
APP_CATEGORY_MEDICAL = 0x00000020,
|
||
|
APP_CATEGORY_BUSINESS = 0x00000040,
|
||
|
APP_CATEGORY_FINANCIAL = 0x00000080,
|
||
|
APP_CATEGORY_EDUCATIONAL = 0x00000100,
|
||
|
APP_CATEGORY_REFERENCE = 0x00000200,
|
||
|
APP_CATEGORY_WEB = 0x00000400,
|
||
|
APP_CATEGORY_DEVELOPMENTTOOL = 0x00000800,
|
||
|
APP_CATEGORY_MULTIMEDIA = 0x00001000,
|
||
|
APP_CATEGORY_VIRUSCLEANER = 0x00002000,
|
||
|
APP_CATEGORY_CONNECTIVITY = 0x00004000,
|
||
|
APP_CATEGORY_MISC = 0x00008000,
|
||
|
APP_CATEGORY_DEMO = 0x01000000,
|
||
|
APP_CATEGORY_PATCH = 0x02000000,
|
||
|
APP_CATEGORY_DATA = 0x04000000,
|
||
|
APP_CATEGORY_ALL = 0x0700ffff
|
||
|
|
||
|
} APP_CATEGORIES;
|
||
|
|
||
|
//
|
||
|
// Association defines
|
||
|
//
|
||
|
|
||
|
typedef enum CONST_APP_ASSOCIATION_TYPES
|
||
|
{
|
||
|
APP_ASSOCIATION_CHILD = 0x40000000,
|
||
|
APP_ASSOCIATION_PARENT = 0x80000000,
|
||
|
APP_ASSOCIATION_INHERITBOTHPATHS = 0x00000001,
|
||
|
APP_ASSOCIATION_INHERITAPPROOTPATH = 0x00000002,
|
||
|
APP_ASSOCIATION_INHERITSETUPROOTPATH = 0x00000004
|
||
|
|
||
|
} APP_ASSOCIATION_TYPES;
|
||
|
|
||
|
//
|
||
|
// Some misc defines
|
||
|
//
|
||
|
|
||
|
typedef enum CONST_MISC_DEFINES
|
||
|
{
|
||
|
MAX_COMPANYNAME_CHARCOUNT = 64,
|
||
|
MAX_SIGNATURE_CHARCOUNT = 64,
|
||
|
MAX_VERSIONSTRING_CHARCOUNT = 16,
|
||
|
MAX_CMDLINE_CHARCOUNT = 255,
|
||
|
MAX_PATH_CHARCOUNT = 255
|
||
|
|
||
|
} MISC_DEFINES;
|
||
|
|
||
|
//
|
||
|
// Error Codes
|
||
|
//
|
||
|
|
||
|
typedef enum CONST_ERROR_CODES
|
||
|
{
|
||
|
APPMAN_E_NOTINITIALIZED = 0x85670001,
|
||
|
APPMAN_E_INVALIDPROPERTYSIZE = 0x85670005,
|
||
|
APPMAN_E_INVALIDDATA = 0x85670006,
|
||
|
APPMAN_E_INVALIDPROPERTY = 0x85670007,
|
||
|
APPMAN_E_READONLYPROPERTY = 0x85670008,
|
||
|
APPMAN_E_PROPERTYNOTSET = 0x85670009,
|
||
|
APPMAN_E_OVERFLOW = 0x8567000a,
|
||
|
APPMAN_E_INVALIDPROPERTYVALUE = 0x8567000c,
|
||
|
APPMAN_E_ACTIONINPROGRESS = 0x8567000d,
|
||
|
APPMAN_E_ACTIONNOTINITIALIZED = 0x8567000e,
|
||
|
APPMAN_E_REQUIREDPROPERTIESMISSING = 0x8567000f,
|
||
|
APPMAN_E_APPLICATIONALREADYEXISTS = 0x85670010,
|
||
|
APPMAN_E_APPLICATIONALREADYLOCKED = 0x85670011,
|
||
|
APPMAN_E_NODISKSPACEAVAILABLE = 0x85670012,
|
||
|
APPMAN_E_UNKNOWNAPPLICATION = 0x85670014,
|
||
|
APPMAN_E_INVALIDPARAMETERS = 0x85670015,
|
||
|
APPMAN_E_OBJECTLOCKED = 0x85670017,
|
||
|
APPMAN_E_INVALIDINDEX = 0x85670018,
|
||
|
APPMAN_E_REGISTRYCORRUPT = 0x85670019,
|
||
|
APPMAN_E_CANNOTASSOCIATE = 0x8567001a,
|
||
|
APPMAN_E_INVALIDASSOCIATION = 0x8567001b,
|
||
|
APPMAN_E_ALREADYASSOCIATED = 0x8567001c,
|
||
|
APPMAN_E_APPLICATIONREQUIRED = 0x8567001d,
|
||
|
APPMAN_E_INVALIDEXECUTECMDLINE = 0x8567001e,
|
||
|
APPMAN_E_INVALIDDOWNSIZECMDLINE = 0x8567001f,
|
||
|
APPMAN_E_INVALIDREINSTALLCMDLINE = 0x85670020,
|
||
|
APPMAN_E_INVALIDUNINSTALLCMDLINE = 0x85670021,
|
||
|
APPMAN_E_INVALIDSELFTESTCMDLINE = 0x85670022,
|
||
|
APPMAN_E_PARENTAPPNOTREADY = 0x85670023,
|
||
|
APPMAN_E_INVALIDSTATE = 0x85670024,
|
||
|
APPMAN_E_INVALIDROOTPATH = 0x85670025,
|
||
|
APPMAN_E_CACHEOVERRUN = 0x85670026,
|
||
|
APPMAN_E_REINSTALLDX = 0x85670028,
|
||
|
APPMAN_E_APPNOTEXECUTABLE = 0x85670029
|
||
|
|
||
|
} ERROR_CODES;
|
||
|
|
||
|
[
|
||
|
uuid(9D4BD41C-508B-4D49-894E-F09242B68AF8),
|
||
|
helpstring("AppEntry Class")
|
||
|
]
|
||
|
coclass AppEntry
|
||
|
{
|
||
|
[default] interface IAppEntry;
|
||
|
};
|
||
|
[
|
||
|
uuid(09A0E8F4-3C5D-4EA3-B56A-4E0731EE861A),
|
||
|
helpstring("AppManager Class")
|
||
|
]
|
||
|
coclass AppManager
|
||
|
{
|
||
|
[default] interface IAppManager;
|
||
|
};
|
||
|
};
|