pub struct Blob { /* private fields */ }Expand description
Um BLOB aberto para leitura no servidor.
Implementations§
Source§impl Blob
impl Blob
Sourcepub fn read_segment(&mut self, conn: &mut Connection) -> Result<Vec<u8>>
pub fn read_segment(&mut self, conn: &mut Connection) -> Result<Vec<u8>>
Lê o próximo bloco do blob (um ou mais segmentos, já concatenados). Retorna
um vetor vazio quando não há mais nada. Após o fim, Self::is_eof fica
verdadeiro.
Sourcepub fn read_to_end(&mut self, conn: &mut Connection) -> Result<Vec<u8>>
pub fn read_to_end(&mut self, conn: &mut Connection) -> Result<Vec<u8>>
Lê o blob inteiro até o fim, concatenando todos os segmentos.
Sourcepub fn close(self, conn: &mut Connection) -> Result<()>
pub fn close(self, conn: &mut Connection) -> Result<()>
Fecha o blob (op_close_blob), consumindo o handle.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Blob
impl RefUnwindSafe for Blob
impl Send for Blob
impl Sync for Blob
impl Unpin for Blob
impl UnsafeUnpin for Blob
impl UnwindSafe for Blob
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more