Struct sync_file::RandomAccessFile[][src]

pub struct RandomAccessFile(_);
Expand description

A file with cross-platform positioned I/O.

Implementations

Attempts to open a file in read-only mode.

See File::open for details.

Opens a file in write-only mode.

See File::create for details.

Attempts to sync all OS-internal metadata to disk.

See File::sync_all for details.

This function is similar to sync_all, except that it may not synchronize file metadata to the filesystem.

See File::sync_data for details.

Truncates or extends the underlying file, updating the size of this file to become size.

See File::set_len for details.

Queries metadata about the underlying file.

See File::metadata for details.

Changes the permissions on the underlying file.

See File::set_permissions for details.

Unwraps the inner File.

The file’s cursor position is unspecified.

Trait Implementations

Extracts the raw file descriptor. Read more

Formats the value using the given formatter. Read more

Creates a new RandomAccessFile from an open File.

Performs the conversion.

Creates a new SyncFile from an open RandomAccessFile.

The cursor starts at the beginning of the file.

Constructs a new instance of Self from the given raw file descriptor. Read more

Consumes this object, returning the raw underlying file descriptor. Read more

Reads a number of bytes starting from a given offset. Read more

Reads the exact number of byte required to fill buf from the given offset. Read more

Writes a number of bytes starting from a given offset. Read more

Attempts to write an entire buffer starting from a given offset. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.