共用方式為


basic_streambuf::pubseekoff

呼叫 seekoff,在衍生類別中覆寫的受保護虛擬函式 (Virtual Function)。

pos_type pubseekoff(
   off_type _Off,
   ios_base::seekdir _Way,
   ios_base::openmode _Which = ios_base::in | ios_base::out
);

參數

  • _Off
    要尋找的位置是相對於 _Way。

  • _Way
    位移作業的開始。 。如需可能的值 seekdir

  • _Which
    以指標位置指定模式。 預設值為可讓您修改和讀取/寫入位置。

傳回值

傳回新位置或一個無效的資料流位置 ( seekoff(_Off, _Way, _Which))。

備註

將指標移至相對 _Way。

需求

標題: <streambuf>

命名空間: std

請參閱

參考

basic_streambuf Class

iostream 程式設計

iostreams 慣例