pub struct TableUpdateRate(/* private fields */);
Expand description
The table update rate for compression/decompression.
You can create this by using the new
method or use one of the constants.
Implementations§
Source§impl TableUpdateRate
impl TableUpdateRate
Sourcepub const FAST: TableUpdateRate
pub const FAST: TableUpdateRate
The fastest table update rate. It has a rate of 20
.
Sourcepub const DEFAULT: TableUpdateRate
pub const DEFAULT: TableUpdateRate
The default table update rate. It has a rate of 8
.
Sourcepub const SLOW: TableUpdateRate
pub const SLOW: TableUpdateRate
A moderately slow table update rate. It has a rate of 2
.
Sourcepub const VERY_SLOW: TableUpdateRate
pub const VERY_SLOW: TableUpdateRate
The slowest table update rate. It has a rate of 1
.
Sourcepub fn new(rate: u32) -> Self
pub fn new(rate: u32) -> Self
Create new TableUpdateRate
from given rate
.
If rate
is greater than the fastest rate, the fastest rate is used. Similarly,
if rate
is lower than the slowest rate, the slowest rate is used.
Sourcepub fn table_update_settings(&self) -> TableUpdateInterval
pub fn table_update_settings(&self) -> TableUpdateInterval
Converts the update rate into TableUpdateInterval
.
Trait Implementations§
Source§impl Clone for TableUpdateRate
impl Clone for TableUpdateRate
Source§fn clone(&self) -> TableUpdateRate
fn clone(&self) -> TableUpdateRate
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 TableUpdateRate
impl Debug for TableUpdateRate
impl Copy for TableUpdateRate
Auto Trait Implementations§
impl Freeze for TableUpdateRate
impl RefUnwindSafe for TableUpdateRate
impl Send for TableUpdateRate
impl Sync for TableUpdateRate
impl Unpin for TableUpdateRate
impl UnwindSafe for TableUpdateRate
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