pub struct WarcWriter<W> { /* private fields */ }
Expand description

A writer which writes records to an output stream.

Implementations

Create a new writer.

Write a single record.

The number of bytes written is returned upon success.

Write a single raw record.

The number of bytes written is returned upon success.

Consume this writer and return the inner writer.

Flushing Compressed Data Streams

This method is necessary to be called at the end of a GZIP-compressed stream. An extra call is needed to flush the buffer of data, and write a trailer to the output stream.

let gzip_stream = writer.into_inner()?;
gzip_writer.finish().into_result()?;

Create a new writer which writes to a file.

Create a new writer which writes to a GZIP-compressed file.

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

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

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.