pub struct BatchEncoder;Expand description
Batch encoding utilities for efficient bulk operations
§Examples
use chie_shared::encoding::BatchEncoder;
// Encode multiple strings at once
let strings = vec!["hello", "world", "chie"];
let encoded = BatchEncoder::encode_strings(&strings).unwrap();
assert!(!encoded.is_empty());Implementations§
Source§impl BatchEncoder
impl BatchEncoder
Sourcepub fn encode_batch<T: BinaryEncode>(items: &[T]) -> ChieResult<Vec<u8>>
pub fn encode_batch<T: BinaryEncode>(items: &[T]) -> ChieResult<Vec<u8>>
Sourcepub fn encode_strings(strings: &[&str]) -> ChieResult<Vec<u8>>
pub fn encode_strings(strings: &[&str]) -> ChieResult<Vec<u8>>
Sourcepub fn encode_u64_batch(values: &[u64]) -> ChieResult<Vec<u8>>
pub fn encode_u64_batch(values: &[u64]) -> ChieResult<Vec<u8>>
Auto Trait Implementations§
impl Freeze for BatchEncoder
impl RefUnwindSafe for BatchEncoder
impl Send for BatchEncoder
impl Sync for BatchEncoder
impl Unpin for BatchEncoder
impl UnwindSafe for BatchEncoder
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