streambuf::seekpos 方法

搜尋至指定位置。

virtual typename details::basic_streambuf<_CharType>::pos_type seekpos(
   typename details::basic_streambuf<_CharType>::pos_type pos,
   std::ios_base::openmode direction
);

參數

  • pos
    資料流開頭的位移。

  • direction
    要搜尋的 I/O 方向 (請參閱<備註>)。

傳回值

位置。 如果作業失敗,則為 EOF。

備註

某些資料流可能有不同的寫入和讀取資料指標。 對於這類資料流,方向參數會定義要移動讀取資料指標還是寫入資料指標。

需求

**標頭:**astreambuf.h

**命名空間:**concurrency::streams

請參閱

參考

streambuf 類別