Enum std::io::SeekFrom1.0.0[][src]

pub enum SeekFrom {
    Start(u64),
    End(i64),
    Current(i64),
}
Expand description

列举可能在 I/O 对象中进行搜索的方法。

Seek trait 使用它。

Variants

Start(u64)

Tuple Fields

0: u64

将偏移量设置为提供的字节数。

End(i64)

Tuple Fields

0: i64

将偏移量设置为此对象的大小加上指定的字节数。

可以在对象的末尾进行查找,但是在字节 0 之前进行查找是错误的。

Current(i64)

Tuple Fields

0: i64

将偏移量设置为当前位置加上指定的字节数。

可以在对象的末尾进行查找,但是在字节 0 之前进行查找是错误的。

Trait Implementations

返回值的副本。 Read more

source 执行复制分配。 Read more

使用给定的格式化程序格式化该值。 Read more

此方法测试 selfother 值是否相等,并由 == 使用。 Read more

此方法测试 !=

Auto Trait Implementations

Blanket Implementations

获取 selfTypeIdRead more

从拥有的值中一成不变地借用。 Read more

从拥有的值中借用。 Read more

执行转换。

执行转换。

获得所有权后的结果类型。

从借用的数据创建拥有的数据,通常是通过克隆。 Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into #41263)

使用借来的数据来替换拥有的数据,通常是通过克隆。 Read more

发生转换错误时返回的类型。

执行转换。

发生转换错误时返回的类型。

执行转换。