Win32 API 日本語リファレンス
ホームDevices.PortableDevices › IPortableDeviceValuesCollection

IPortableDeviceValuesCollection

COM
IID6e3f2d79-4e07-48c4-8208-d8c2e5af4a99継承元IUnknown自前メソッド開始 vtbl3

メソッド 5

vtbl = vtable インデックス(0始まり)。HSP等からCOMメソッドをインデックス指定で呼ぶ際に使用します。0〜2 は IUnknown。

vtbl 3 HRESULT GetCount(DWORD* pcElems)
pcElemsDWORD*inコレクション内のIPortableDeviceValues要素の総数を受け取る出力先。
vtbl 4 HRESULT GetAt(DWORD dwIndex, IPortableDeviceValues** ppValues)
dwIndexDWORDin取得する要素の0始まりのインデックス。
ppValuesIPortableDeviceValues**out指定位置のIPortableDeviceValuesを受け取る出力先。
vtbl 5 HRESULT Add(IPortableDeviceValues* pValues)
pValuesIPortableDeviceValues*inコレクションに追加するIPortableDeviceValuesへのポインタ。
vtbl 6 HRESULT Clear()
vtbl 7 HRESULT RemoveAt(DWORD dwIndex)
dwIndexDWORDin削除する要素の0始まりのインデックス。

HSP用 COM定義

#usecom / #comfunc によるHSPのCOM呼び出し定義。数字は vtbl インデックス(0始まり)。クラスIDが無い場合 #usecom の末尾は "{}"、ある場合は "{CLSID}"

出力引数:
#define global IID_IPortableDeviceValuesCollection "{6E3F2D79-4E07-48C4-8208-D8C2E5AF4A99}"
#usecom global IPortableDeviceValuesCollection IID_IPortableDeviceValuesCollection "{3882134D-14CF-4220-9CB4-435F86D83F60}"
#comfunc global IPortableDeviceValuesCollection_GetCount  3 var
#comfunc global IPortableDeviceValuesCollection_GetAt     4 int,sptr
#comfunc global IPortableDeviceValuesCollection_Add       5 sptr
#comfunc global IPortableDeviceValuesCollection_Clear     6
#comfunc global IPortableDeviceValuesCollection_RemoveAt  7 int
; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。
; ※#usecom 末尾は CoCreateInstance 用のクラスID(コクラスCLSID, SDKから自動取得)。
; ※出力/バッファ引数は var(変数直渡し)。varptr 方式にも切替可。
; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。