Struct ps_datachunk::Compressor
source · pub struct Compressor { /* private fields */ }
Implementations§
source§impl Compressor
impl Compressor
pub fn new() -> Compressor
pub fn compress_into( &self, data: &[u8], out_data: &mut [u8], ) -> Result<usize, PsDeflateError>
pub fn compress(&self, data: &[u8]) -> Result<Vec<u8>, PsDeflateError>
pub fn decompress_into( &self, data: &[u8], out_data: &mut [u8], ) -> Result<usize, PsDeflateError>
pub fn decompress( &self, data: &[u8], out_size: usize, ) -> Result<Vec<u8>, PsDeflateError>
Trait Implementations§
source§impl Clone for Compressor
impl Clone for Compressor
source§fn clone(&self) -> Compressor
fn clone(&self) -> Compressor
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Default for Compressor
impl Default for Compressor
source§fn default() -> Compressor
fn default() -> Compressor
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for Compressor
impl !RefUnwindSafe for Compressor
impl Send for Compressor
impl !Sync for Compressor
impl Unpin for Compressor
impl UnwindSafe for Compressor
Blanket Implementations§
source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.