pub trait SeekExt {
// Required methods
fn stream_length(&mut self) -> Result<u64>;
fn align(&mut self, align: u64) -> Result<u64>;
fn seek_to_end(&mut self) -> Result<u64>;
}Expand description
A trait to help to seek in a stream.
Required Methods§
Sourcefn stream_length(&mut self) -> Result<u64>
fn stream_length(&mut self) -> Result<u64>
Returns the length of the stream.
Sourcefn align(&mut self, align: u64) -> Result<u64>
fn align(&mut self, align: u64) -> Result<u64>
Aligns the current position to the given alignment. Returns the new position after alignment.
Sourcefn seek_to_end(&mut self) -> Result<u64>
fn seek_to_end(&mut self) -> Result<u64>
Seeks to the end of the stream.