pub struct RawChunk<'a> {
pub raw_data: &'a [u8],
/* private fields */
}
Expand description
A raw compressed chunk, holds the compression type used.
And the specific chunk byte slice from the region data
This is used when getting chunk data from a region file.
Fields§
§raw_data: &'a [u8]
Implementations§
Source§impl<'a> RawChunk<'a>
impl<'a> RawChunk<'a>
Sourcepub fn get_compression_type(&self) -> CompressionType
pub fn get_compression_type(&self) -> CompressionType
Get the chunks CompressionType
Sourcepub fn new(data: &'a [u8], compression: CompressionType) -> RawChunk<'_>
pub fn new(data: &'a [u8], compression: CompressionType) -> RawChunk<'_>
Creates a new raw chunk from it’s bytes and compression type
Trait Implementations§
Source§impl<'a> Ord for RawChunk<'a>
impl<'a> Ord for RawChunk<'a>
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<'a> PartialOrd for RawChunk<'a>
impl<'a> PartialOrd for RawChunk<'a>
impl<'a> Eq for RawChunk<'a>
impl<'a> StructuralPartialEq for RawChunk<'a>
Auto Trait Implementations§
impl<'a> Freeze for RawChunk<'a>
impl<'a> RefUnwindSafe for RawChunk<'a>
impl<'a> Send for RawChunk<'a>
impl<'a> Sync for RawChunk<'a>
impl<'a> Unpin for RawChunk<'a>
impl<'a> UnwindSafe for RawChunk<'a>
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