pub struct BlockHandle {
pub offset: u64,
pub size: u64,
}
Fields§
§offset: u64
§size: u64
Implementations§
Source§impl BlockHandle
impl BlockHandle
pub fn new(offset: u64, size: u64) -> Self
pub fn null() -> Self
pub fn is_null(&self) -> bool
pub fn decode_from<R: Read>(reader: &mut R) -> Result<Self>
pub fn encode_to<W: Write>(&self, writer: &mut W) -> Result<()>
pub fn encoded_length(&self) -> usize
pub fn decode_from_bytes(data: &[u8]) -> Result<(Self, usize)>
pub fn encode_to_bytes(&self) -> Result<Vec<u8>>
Trait Implementations§
Source§impl Clone for BlockHandle
impl Clone for BlockHandle
Source§fn clone(&self) -> BlockHandle
fn clone(&self) -> BlockHandle
Returns a duplicate 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 Debug for BlockHandle
impl Debug for BlockHandle
Source§impl PartialEq for BlockHandle
impl PartialEq for BlockHandle
impl Eq for BlockHandle
impl StructuralPartialEq for BlockHandle
Auto Trait Implementations§
impl Freeze for BlockHandle
impl RefUnwindSafe for BlockHandle
impl Send for BlockHandle
impl Sync for BlockHandle
impl Unpin for BlockHandle
impl UnwindSafe for BlockHandle
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