pub type OutFile<Row> = NpyWriter<Row, BufWriter<File>>;
👎Deprecated since 0.5.0: Doesn’t carry its weight. Use to_file_1d instead, or replicate the original behavior with Builder::new().default_dtype().begin_1d(std::io::BufWriter::new(std::fs::File::create(path)?))
Expand description
NpyWriter
that writes an entire file.
Aliased Type§
struct OutFile<Row> { /* private fields */ }
Implementations§
source§impl<Row: AutoSerialize> OutFile<Row>
impl<Row: AutoSerialize> OutFile<Row>
sourcepub fn open<P: AsRef<Path>>(path: P) -> Result<Self>
👎Deprecated since 0.5.0: Doesn’t carry its weight. Use to_file_1d instead, or replicate the original behavior with Builder::new().default_dtype().begin_1d(std::io::BufWriter::new(std::fs::File::create(path)?))
pub fn open<P: AsRef<Path>>(path: P) -> Result<Self>
Create a file, using the default format for the given type.
source§impl<Row: Serialize> OutFile<Row>
impl<Row: Serialize> OutFile<Row>
sourcepub fn close(self) -> Result<()>
👎Deprecated since 0.5.0: use .finish() instead
pub fn close(self) -> Result<()>
Finish writing the file and close it. Alias for NpyWriter::finish
.
If omitted, the file will be closed on drop automatically, ignoring any errors encountered during the process.