[−][src]Struct binjs_io::io::statistics::PerUserExtensibleKind
During compression, we typically deal with both grammar-fixed data (e.g. the list of possible values in a string enum) and user-extensible data (e.g. string literals).
This container is meant to store data associated with user-extensible data. This serves typically to store per-kind compression settings, per-kind compressed/decompressed data, dictionaries, etc.
Fields
floats: T
unsigned_longs: T
property_keys: T
identifier_names: T
string_literals: T
list_lengths: T
Methods
impl<T> PerUserExtensibleKind<T>
[src]
pub fn with<F>(f: F) -> Self where
F: Fn(&str) -> T,
[src]
F: Fn(&str) -> T,
Initialize a new PerUserExtensibleKind
.
pub fn into_with<F, U>(self, f: F) -> PerUserExtensibleKind<U> where
F: Fn(&str, T) -> U,
[src]
F: Fn(&str, T) -> U,
Convert a PerUserExtensibleKind
into another one.
pub fn iter(&self) -> impl Iterator<Item = (&'static str, &T)>
[src]
pub fn iter_mut(&mut self) -> impl Iterator<Item = (&'static str, &mut T)>
[src]
pub fn into_iter(self) -> impl Iterator<Item = (&'static str, T)>
[src]
pub fn get(&self, field_name: &str) -> Option<&T>
[src]
Access a field by its name.
This method is typically used to simplify parsing a file that
contains sections explicitly labelled "bools", "floats", etc.
In such case, field_name
is expected to be a user input.
Return None
if field_name
is not one of the field names.
pub fn get_mut(&mut self, field_name: &str) -> Option<&mut T>
[src]
pub fn get_mut_b(&mut self, field_name: &[u8]) -> Option<&mut T>
[src]
Access a field by its name, specified as a sequence of bytes.
This method is typically used to simplify parsing a file that
contains sections explicitly labelled "bools", "floats", etc.
In such case, field_name
is expected to be a user input.
Return None
if field_name
is not one of the field names.
pub fn get_b(&self, field_name: &[u8]) -> Option<&T>
[src]
impl PerUserExtensibleKind<Writer<LengthWriter>>
[src]
pub fn into_statistics(self) -> PerUserExtensibleKind<Bytes>
[src]
Finalize and return the number of compressed bytes written.
This number is determined by examining the underlying LengthWriter.
Trait Implementations
impl<T: Add<Output = T>> Add<PerUserExtensibleKind<T>> for PerUserExtensibleKind<T>
[src]
type Output = PerUserExtensibleKind<T>
The resulting type after applying the +
operator.
fn add(self, rhs: PerUserExtensibleKind<T>) -> PerUserExtensibleKind<T>
[src]
impl<T: AddAssign> AddAssign<PerUserExtensibleKind<T>> for PerUserExtensibleKind<T>
[src]
fn add_assign(&mut self, rhs: PerUserExtensibleKind<T>)
[src]
impl<T: Clone> Clone for PerUserExtensibleKind<T>
[src]
fn clone(&self) -> PerUserExtensibleKind<T>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<T: Debug> Debug for PerUserExtensibleKind<T>
[src]
impl<T: Default> Default for PerUserExtensibleKind<T>
[src]
fn default() -> PerUserExtensibleKind<T>
[src]
impl Display for PerUserExtensibleKind<BytesAndInstances>
[src]
Auto Trait Implementations
impl<T> RefUnwindSafe for PerUserExtensibleKind<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Send for PerUserExtensibleKind<T> where
T: Send,
T: Send,
impl<T> Sync for PerUserExtensibleKind<T> where
T: Sync,
T: Sync,
impl<T> Unpin for PerUserExtensibleKind<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for PerUserExtensibleKind<T> where
T: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Downcast for T where
T: Any,
[src]
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
[src]
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
[src]
fn as_any(&self) -> &(dyn Any + 'static)
[src]
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]
impl<T> DowncastSync for T where
T: Send + Sync + Any,
[src]
T: Send + Sync + Any,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src]
V: MultiLane<T>,