Struct git2::OdbWriter [−][src]
pub struct OdbWriter<'repo> { /* fields omitted */ }
Expand description
A structure to represent a git ODB wstream
Implementations
impl<'repo> OdbWriter<'repo>
[src]
impl<'repo> OdbWriter<'repo>
[src]pub fn finalize(&mut self) -> Result<Oid, Error>
[src]
pub fn finalize(&mut self) -> Result<Oid, Error>
[src]Finish writing to an ODB stream
This method can be used to finalize writing object to the database and get an identifier. The object will take its final name and will be available to the odb. This method will fail if the total number of received bytes differs from the size declared with odb_writer() Attepting write after finishing will be ignored.
Trait Implementations
impl<'repo> Write for OdbWriter<'repo>
[src]
impl<'repo> Write for OdbWriter<'repo>
[src]fn write(&mut self, buf: &[u8]) -> Result<usize>
[src]
fn write(&mut self, buf: &[u8]) -> Result<usize>
[src]Write a buffer into this writer, returning how many bytes were written. Read more
fn flush(&mut self) -> Result<()>
[src]
fn flush(&mut self) -> Result<()>
[src]Flush this output stream, ensuring that all intermediately buffered contents reach their destination. Read more
fn is_write_vectored(&self) -> bool
[src]
fn is_write_vectored(&self) -> bool
[src]can_vector
)Determines if this Write
r has an efficient write_vectored
implementation. Read more
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
1.0.0[src]
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
1.0.0[src]Attempts to write an entire buffer into this writer. Read more
fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
[src]
fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
[src]write_all_vectored
)Attempts to write multiple buffers into this writer. Read more