Enum ident_case::RenameRule [−][src]
A casing rule for renaming Rust identifiers.
Variants
No-op rename rule.
Rename direct children to “lowercase” style.
Rename direct children to “PascalCase” style, as typically used for enum variants.
Rename direct children to “camelCase” style.
Rename direct children to “snake_case” style, as commonly used for fields.
Rename direct children to “SCREAMING_SNAKE_CASE” style, as commonly used for constants.
Rename direct children to “kebab-case” style.
Implementations
impl RenameRule
[src]
pub fn apply_to_variant<S: AsRef<str>>(&self, variant: S) -> String
[src]
Change case of a PascalCase
variant.
pub fn apply_to_field<S: AsRef<str>>(&self, field: S) -> String
[src]
Change case of a snake_case
field.
Trait Implementations
impl Clone for RenameRule
[src]
fn clone(&self) -> RenameRule
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for RenameRule
[src]
impl Debug for RenameRule
[src]
impl Default for RenameRule
[src]
impl Eq for RenameRule
[src]
impl FromStr for RenameRule
[src]
type Err = ()
The associated error which can be returned from parsing.
fn from_str(rename_all_str: &str) -> Result<Self, Self::Err>
[src]
impl PartialEq<RenameRule> for RenameRule
[src]
fn eq(&self, other: &RenameRule) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl StructuralEq for RenameRule
[src]
impl StructuralPartialEq for RenameRule
[src]
Auto Trait Implementations
impl RefUnwindSafe for RenameRule
impl Send for RenameRule
impl Sync for RenameRule
impl Unpin for RenameRule
impl UnwindSafe for RenameRule
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,
pub fn borrow_mut(&mut self) -> &mut T
[src]
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.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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.
pub 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>,