共用方式為


IByteBuffer::Stat 方法

[ Stat 方法可用於需求一節中指定的作業系統。 它不適用於 Windows Server 2003 Service Pack 1 (SP1) 及更新版本、Windows Vista、Windows Server 2008 和後續版本的作業系統。 IStream介面提供類似的功能。]

Stat方法會從資料流程物件擷取統計資訊。

語法

HRESULT Stat(
  [out] LPSTATSTRUCT pstatstg,
  [in]  LONG         grfStatFlag
);

參數

pstatstg [out]

指向這個方法放置這個資料流程物件相關資訊的 STATSTRUCT 結構。 如果發生錯誤,則此指標為 Null

grfStatFlag [in]

指定這個方法不會傳回 STATSTRUCT 結構中的某些欄位,因此會儲存記憶體配置作業。 值取自 STATFLAG 列舉

傳回值

傳回值為 HRESULT。 值S_OK表示呼叫成功。

備註

IByteBuffer::Stat方法會擷取STATSTRUCT結構的指標,其中包含此開啟資料流程的相關資訊。

範例

下列範例顯示從資料流程擷取統計資訊。

STATSTRUCT  statstr;
HRESULT     hr;

// Retrieve the statistical information.
hr = pIByteBuff->Stat(&statstr,
                      STATFLAG_DEFAULT);
if (FAILED(hr))
  printf("Failed IByteBuffer::Stat\n");
else
  // Use statstr as needed.

規格需求

需求
最低支援的用戶端
Windows XP [僅限傳統型應用程式]
最低支援的伺服器
Windows Server 2003 [僅限桌面應用程式]
用戶端支援結束
Windows XP
伺服器終止支援
Windows Server 2003
標頭
Scardssp.h
類型程式庫
Scardssp.tlb
DLL
Scardssp.dll
IID
IID_IByteBuffer定義為 E126F8FE-A7AF-11D0-B88A-00C04FD424B9