#[non_exhaustive]pub enum CaseNormalization {
Preserve,
AsciiLowercase,
UnicodeLowercase,
PlatformDefault,
}Expand description
How to transform letter case in a comparison key or token.
§Platform notes
- Windows is normally case-insensitive for filesystem paths.
- Linux is normally case-sensitive.
- macOS may be either, depending on the volume.
- Case folding is not proof of filesystem identity.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Preserve
Leave case unchanged.
AsciiLowercase
ASCII A–Z → a–z only.
UnicodeLowercase
Unicode lowercase mapping (str::to_lowercase).
PlatformDefault
Platform-oriented default: ASCII lowercase on Windows; preserve elsewhere.
Implementations§
Trait Implementations§
Source§impl Clone for CaseNormalization
impl Clone for CaseNormalization
Source§fn clone(&self) -> CaseNormalization
fn clone(&self) -> CaseNormalization
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CaseNormalization
Source§impl Debug for CaseNormalization
impl Debug for CaseNormalization
Source§impl Default for CaseNormalization
impl Default for CaseNormalization
Source§fn default() -> CaseNormalization
fn default() -> CaseNormalization
Returns the “default value” for a type. Read more
impl Eq for CaseNormalization
Source§impl PartialEq for CaseNormalization
impl PartialEq for CaseNormalization
impl StructuralPartialEq for CaseNormalization
Auto Trait Implementations§
impl Freeze for CaseNormalization
impl RefUnwindSafe for CaseNormalization
impl Send for CaseNormalization
impl Sync for CaseNormalization
impl Unpin for CaseNormalization
impl UnsafeUnpin for CaseNormalization
impl UnwindSafe for CaseNormalization
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