Win32 API 日本語リファレンス
ホームStorage.Xps › IXpsOMDocumentCollection

IXpsOMDocumentCollection

COM
IIDd1c87f0d-e947-4754-8a25-971478f7e83e継承元IUnknown自前メソッド開始 vtbl3

メソッド 6

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

vtbl 3 HRESULT GetCount(DWORD* count)
countDWORD*outコレクション内のドキュメント数を受け取る。
vtbl 4 HRESULT GetAt(DWORD index, IXpsOMDocument** document)
indexDWORDin取得する要素の 0 基点のインデックスを指定する。
documentIXpsOMDocument**out指定インデックスのドキュメントへのポインタを受け取る。
vtbl 5 HRESULT InsertAt(DWORD index, IXpsOMDocument* document)
indexDWORDin挿入位置を示す 0 基点のインデックスを指定する。
documentIXpsOMDocument*in挿入するドキュメントを指定する。
vtbl 6 HRESULT RemoveAt(DWORD index)
indexDWORDin削除する要素の 0 基点のインデックスを指定する。
vtbl 7 HRESULT SetAt(DWORD index, IXpsOMDocument* document)
indexDWORDin置き換える要素の 0 基点のインデックスを指定する。
documentIXpsOMDocument*in指定位置に設定するドキュメントを指定する。
vtbl 8 HRESULT Append(IXpsOMDocument* document)
documentIXpsOMDocument*inコレクション末尾に追加するドキュメントを指定する。

HSP用 COM定義

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

出力引数:
#define global IID_IXpsOMDocumentCollection "{D1C87F0D-E947-4754-8A25-971478F7E83E}"
#usecom global IXpsOMDocumentCollection IID_IXpsOMDocumentCollection "{}"
#comfunc global IXpsOMDocumentCollection_GetCount  3 var
#comfunc global IXpsOMDocumentCollection_GetAt     4 int,sptr
#comfunc global IXpsOMDocumentCollection_InsertAt  5 int,sptr
#comfunc global IXpsOMDocumentCollection_RemoveAt  6 int
#comfunc global IXpsOMDocumentCollection_SetAt     7 int,sptr
#comfunc global IXpsOMDocumentCollection_Append    8 sptr
; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。
; ※このインターフェースは直接 CoCreateInstance するクラスIDが無いため "{}"(他メソッド/アクティベーションで取得)。
; ※出力/バッファ引数は var(変数直渡し)。varptr 方式にも切替可。
; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。