Enum xz2::stream::MatchFinder
source · [−]pub enum MatchFinder {
HashChain3,
HashChain4,
BinaryTree2,
BinaryTree3,
BinaryTree4,
}
Expand description
Match finders
Match finder has major effect on both speed and compression ratio. Usually hash chains are faster than binary trees.
If you will use SyncFlush
often, the hash chains may be a better choice,
because binary trees get much higher compression ratio penalty with
SyncFlush
.
The memory usage formulas are only rough estimates, which are closest to reality when dict_size is a power of two. The formulas are more complex in reality, and can also change a little between liblzma versions.
Variants
HashChain3
Hash Chain with 2- and 3-byte hashing
HashChain4
Hash Chain with 2-, 3-, and 4-byte hashing
BinaryTree2
Binary Tree with 2-byte hashing
BinaryTree3
Binary Tree with 2- and 3-byte hashing
BinaryTree4
Binary Tree with 2-, 3-, and 4-byte hashing
Implementations
sourceimpl MatchFinder
impl MatchFinder
sourcepub fn is_supported(&self) -> bool
pub fn is_supported(&self) -> bool
Test if this match finder is supported in this build of liblzma.
Trait Implementations
sourceimpl Clone for MatchFinder
impl Clone for MatchFinder
sourcefn clone(&self) -> MatchFinder
fn clone(&self) -> MatchFinder
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for MatchFinder
Auto Trait Implementations
impl RefUnwindSafe for MatchFinder
impl Send for MatchFinder
impl Sync for MatchFinder
impl Unpin for MatchFinder
impl UnwindSafe for MatchFinder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more