首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往

std::basic_streambuf::pubseekpos

pos_type pubseekpos( pos_type pos, ios_base::openmode which = ios_base::in | ios_base::out );

(1)

?

protected: virtual pos_type seekpos( pos_type pos, ios_base::openmode which = ios_base::in | ios_base::out);

(2)

?

将输入和/或输出序列的位置指示器设置为绝对位置。

1%29次电话seekpos(pos, which)最派生的类。

2%29此函数的基类版本没有任何影响。派生类可以重写此函数以允许位置指示器的绝对定位。

参数

pos

-

absolute position to set the position indicator to.

which

-

defines which of the input and/or output sequences to affect. It can be one or a combination of the following constants: Constant Explanation in affect the input sequence out affect the output sequence

Constant

Explanation

in

affect the input sequence

out

affect the output sequence

Constant

Explanation

in

affect the input sequence

out

affect the output sequence

返回值

1%29seekpos(pos, which)...

2%29由位置指示器定义的最终绝对位置。基类版本返回pos_type(off_type(-1))...

另见

pubseekoff

invokes seekoff() (public member function)

代码语言:txt
复制
 ? cppreference.com

在CreativeCommonsAttribution下授权-ShareAlike未移植许可v3.0。

扫码关注腾讯云开发者

领取腾讯云代金券

http://www.vxiaotou.com