ホーム › System.UpdateAgent › IUpdateInstaller
IUpdateInstaller
COMIDispatch (デュアル)✅ IDispatch を実装(デュアルインターフェース)。HSP では
comobj 経由でメソッド名による遅延バインド呼び出しができます(vtableインデックス不要)。メソッド 21
vtbl = vtable インデックス(0始まり)。IDispatch 実装のため HSP ではメソッド名でも呼べます(上記)。低レベルの index 呼び出し用に vtbl も掲載。0〜2 は IUnknown。
| retval | LPWSTR* | out | 現在設定されているクライアントアプリケーション識別子を受け取る文字列ポインタである。呼び出し元がイベントログ等で使用する。 |
| value | LPWSTR | in | 更新の操作を識別するために設定するクライアントアプリケーション識別子の文字列を指定する。 |
vtbl 9 HRESULT get_IsForced(VARIANT_BOOL* retval)
| retval | VARIANT_BOOL* | out | インストールが強制モードで実行されるかどうかを受け取る VARIANT_BOOL へのポインタである。 |
vtbl 10 HRESULT put_IsForced(VARIANT_BOOL value)
| value | VARIANT_BOOL | in | 更新が既にインストール済みであっても強制的に再インストールするかどうかを指定する VARIANT_BOOL である。 |
| retval | HWND* | out | ダイアログ等の親として使用されるウィンドウハンドルを受け取る HWND へのポインタである。 |
| value | HWND | in | インストール時に表示される UI の親となるウィンドウハンドルを指定する。 |
| value | IUnknown* | in | 親ウィンドウを表す IUnknown インターフェイスへのポインタを指定する。NULL を指定すると親ウィンドウを設定しない。 |
| retval | IUnknown** | out | 設定されている親ウィンドウの IUnknown インターフェイスを受け取るポインタである。 |
vtbl 15 HRESULT get_Updates(IUpdateCollection** retval)
| retval | IUpdateCollection** | out | インストールまたはアンインストール対象として設定された更新のコレクションを受け取る IUpdateCollection へのポインタである。 |
vtbl 16 HRESULT put_Updates(IUpdateCollection* value)
| value | IUpdateCollection* | in | インストールまたはアンインストール対象とする更新のコレクションを指定する IUpdateCollection へのポインタである。 |
vtbl 17 HRESULT BeginInstall(IUnknown* onProgressChanged, IUnknown* onCompleted, VARIANT state, IInstallationJob** retval)
| onProgressChanged | IUnknown* | in | 進捗が変化したときに呼び出されるコールバック(IInstallationProgressChangedCallback)の IUnknown ポインタを指定する。 |
| onCompleted | IUnknown* | in | インストール完了時に呼び出されるコールバック(IInstallationCompletedCallback)の IUnknown ポインタを指定する。 |
| state | VARIANT | in | コールバックへ引き渡される呼び出し元定義の状態オブジェクトを格納する VARIANT である。 |
| retval | IInstallationJob** | out | 非同期インストール操作を表す IInstallationJob を受け取るポインタである。 |
vtbl 18 HRESULT BeginUninstall(IUnknown* onProgressChanged, IUnknown* onCompleted, VARIANT state, IInstallationJob** retval)
| onProgressChanged | IUnknown* | in | 進捗が変化したときに呼び出されるコールバック(IInstallationProgressChangedCallback)の IUnknown ポインタを指定する。 |
| onCompleted | IUnknown* | in | アンインストール完了時に呼び出されるコールバック(IInstallationCompletedCallback)の IUnknown ポインタを指定する。 |
| state | VARIANT | in | コールバックへ引き渡される呼び出し元定義の状態オブジェクトを格納する VARIANT である。 |
| retval | IInstallationJob** | out | 非同期アンインストール操作を表す IInstallationJob を受け取るポインタである。 |
vtbl 19 HRESULT EndInstall(IInstallationJob* value, IInstallationResult** retval)
| value | IInstallationJob* | in | BeginInstall で開始した非同期インストール操作を表す IInstallationJob を指定する。 |
| retval | IInstallationResult** | out | インストールの結果を受け取る IInstallationResult へのポインタである。 |
vtbl 20 HRESULT EndUninstall(IInstallationJob* value, IInstallationResult** retval)
| value | IInstallationJob* | in | BeginUninstall で開始した非同期アンインストール操作を表す IInstallationJob を指定する。 |
| retval | IInstallationResult** | out | アンインストールの結果を受け取る IInstallationResult へのポインタである。 |
vtbl 21 HRESULT Install(IInstallationResult** retval)
| retval | IInstallationResult** | out | 同期的に実行したインストールの結果を受け取る IInstallationResult へのポインタである。 |
vtbl 22 HRESULT RunWizard(LPWSTR dialogTitle, IInstallationResult** retval)
| dialogTitle | LPWSTR | in | ウィザードのダイアログに表示するタイトル文字列を指定する。NULL を指定すると既定のタイトルが使用される。 |
| retval | IInstallationResult** | out | ウィザードによるインストールの結果を受け取る IInstallationResult へのポインタである。 |
vtbl 23 HRESULT get_IsBusy(VARIANT_BOOL* retval)
| retval | VARIANT_BOOL* | out | インストーラーが現在インストールまたはアンインストールを実行中かどうかを受け取る VARIANT_BOOL へのポインタである。 |
vtbl 24 HRESULT Uninstall(IInstallationResult** retval)
| retval | IInstallationResult** | out | 同期的に実行したアンインストールの結果を受け取る IInstallationResult へのポインタである。 |
vtbl 25 HRESULT get_AllowSourcePrompts(VARIANT_BOOL* retval)
| retval | VARIANT_BOOL* | out | ソースメディアの要求プロンプトを許可するかどうかを受け取る VARIANT_BOOL へのポインタである。 |
vtbl 26 HRESULT put_AllowSourcePrompts(VARIANT_BOOL value)
| value | VARIANT_BOOL | in | インストール中にソースメディアの要求プロンプトを許可するかどうかを指定する VARIANT_BOOL である。 |
vtbl 27 HRESULT get_RebootRequiredBeforeInstallation(VARIANT_BOOL* retval)
| retval | VARIANT_BOOL* | out | インストール前に再起動が必要かどうかを受け取る VARIANT_BOOL へのポインタである。 |
HSP用 COM定義
#usecom / #comfunc によるHSPのCOM呼び出し定義。数字は vtbl インデックス(0始まり)。クラスIDが無い場合 #usecom の末尾は "{}"、ある場合は "{CLSID}"。
出力引数:
#define global IID_IUpdateInstaller "{7B929C68-CCDC-4226-96B1-8724600B54C2}" #usecom global IUpdateInstaller IID_IUpdateInstaller "{D2E0FE7F-D23E-48E1-93C0-6FA8CC346474}" #comfunc global IUpdateInstaller_get_ClientApplicationID 7 var #comfunc global IUpdateInstaller_put_ClientApplicationID 8 wstr #comfunc global IUpdateInstaller_get_IsForced 9 var #comfunc global IUpdateInstaller_put_IsForced 10 int #comfunc global IUpdateInstaller_get_ParentHwnd 11 sptr #comfunc global IUpdateInstaller_put_ParentHwnd 12 sptr #comfunc global IUpdateInstaller_put_ParentWindow 13 sptr #comfunc global IUpdateInstaller_get_ParentWindow 14 sptr #comfunc global IUpdateInstaller_get_Updates 15 sptr #comfunc global IUpdateInstaller_put_Updates 16 sptr #comfunc global IUpdateInstaller_BeginInstall 17 sptr,sptr,int,sptr #comfunc global IUpdateInstaller_BeginUninstall 18 sptr,sptr,int,sptr #comfunc global IUpdateInstaller_EndInstall 19 sptr,sptr #comfunc global IUpdateInstaller_EndUninstall 20 sptr,sptr #comfunc global IUpdateInstaller_Install 21 sptr #comfunc global IUpdateInstaller_RunWizard 22 wstr,sptr #comfunc global IUpdateInstaller_get_IsBusy 23 var #comfunc global IUpdateInstaller_Uninstall 24 sptr #comfunc global IUpdateInstaller_get_AllowSourcePrompts 25 var #comfunc global IUpdateInstaller_put_AllowSourcePrompts 26 int #comfunc global IUpdateInstaller_get_RebootRequiredBeforeInstallation 27 var ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※#usecom 末尾は CoCreateInstance 用のクラスID(コクラスCLSID, SDKから自動取得)。 ; ※出力/バッファ引数は var(変数直渡し)。varptr 方式にも切替可。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。 ; ※IDispatch 実装。HSP では comobj 経由でメソッド名による呼び出しも可能(vtbl 不要)。#define global IID_IUpdateInstaller "{7B929C68-CCDC-4226-96B1-8724600B54C2}" #usecom global IUpdateInstaller IID_IUpdateInstaller "{D2E0FE7F-D23E-48E1-93C0-6FA8CC346474}" #comfunc global IUpdateInstaller_get_ClientApplicationID 7 sptr #comfunc global IUpdateInstaller_put_ClientApplicationID 8 wstr #comfunc global IUpdateInstaller_get_IsForced 9 sptr #comfunc global IUpdateInstaller_put_IsForced 10 int #comfunc global IUpdateInstaller_get_ParentHwnd 11 sptr #comfunc global IUpdateInstaller_put_ParentHwnd 12 sptr #comfunc global IUpdateInstaller_put_ParentWindow 13 sptr #comfunc global IUpdateInstaller_get_ParentWindow 14 sptr #comfunc global IUpdateInstaller_get_Updates 15 sptr #comfunc global IUpdateInstaller_put_Updates 16 sptr #comfunc global IUpdateInstaller_BeginInstall 17 sptr,sptr,int,sptr #comfunc global IUpdateInstaller_BeginUninstall 18 sptr,sptr,int,sptr #comfunc global IUpdateInstaller_EndInstall 19 sptr,sptr #comfunc global IUpdateInstaller_EndUninstall 20 sptr,sptr #comfunc global IUpdateInstaller_Install 21 sptr #comfunc global IUpdateInstaller_RunWizard 22 wstr,sptr #comfunc global IUpdateInstaller_get_IsBusy 23 sptr #comfunc global IUpdateInstaller_Uninstall 24 sptr #comfunc global IUpdateInstaller_get_AllowSourcePrompts 25 sptr #comfunc global IUpdateInstaller_put_AllowSourcePrompts 26 int #comfunc global IUpdateInstaller_get_RebootRequiredBeforeInstallation 27 sptr ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※#usecom 末尾は CoCreateInstance 用のクラスID(コクラスCLSID, SDKから自動取得)。 ; ※出力/バッファ引数はポインタ方式(token=sptr / 呼び出しは varptr(変数))。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。 ; ※IDispatch 実装。HSP では comobj 経由でメソッド名による呼び出しも可能(vtbl 不要)。