pub enum NameTransform {
Identity,
LowerSnakeCase,
UpperSnakeCase,
LowerCamelCase,
UpperCamelCase,
}Expand description
The rewriting strategy applied to various kinds of named program elements,
such as function, variable, and type names.
In the CodegenParams struct, optional instances of this transform are
specified, where None means “default for the programming language”.
Variants§
Identity
Don’t touch it!
LowerSnakeCase
lower_snake_case. Isn’t SnakeCase spelled with camel case ironic, by the way?
UpperSnakeCase
UPPER_SNAKE_CASE. Use this only when you are frustrated and want to yell.
LowerCamelCase
lowerCamelCase.
UpperCamelCase
UpperCamelCase, also known as PascalCase.
Trait Implementations§
Source§impl Clone for NameTransform
impl Clone for NameTransform
Source§fn clone(&self) -> NameTransform
fn clone(&self) -> NameTransform
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 NameTransform
impl Debug for NameTransform
Source§impl Hash for NameTransform
impl Hash for NameTransform
Source§impl Ord for NameTransform
impl Ord for NameTransform
Source§fn cmp(&self, other: &NameTransform) -> Ordering
fn cmp(&self, other: &NameTransform) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for NameTransform
impl PartialEq for NameTransform
Source§impl PartialOrd for NameTransform
impl PartialOrd for NameTransform
impl Copy for NameTransform
impl Eq for NameTransform
impl StructuralPartialEq for NameTransform
Auto Trait Implementations§
impl Freeze for NameTransform
impl RefUnwindSafe for NameTransform
impl Send for NameTransform
impl Sync for NameTransform
impl Unpin for NameTransform
impl UnwindSafe for NameTransform
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