pub struct Inflector;Expand description
Static facade over the application-global Inflections.
All methods delegate to the global instance initialised by init_inflections
(or default English rules if init_inflections was never called).
Implementations§
Source§impl Inflector
impl Inflector
pub fn pluralize(s: &str) -> String
pub fn singularize(s: &str) -> String
pub fn camelize(s: &str) -> String
pub fn camelize_lower(s: &str) -> String
pub fn underscore(s: &str) -> String
pub fn dasherize(s: &str) -> String
pub fn humanize(s: &str) -> String
pub fn tableize(s: &str) -> String
pub fn classify(s: &str) -> String
pub fn foreign_key(s: &str) -> String
pub fn constantize(s: &str) -> String
Auto Trait Implementations§
impl Freeze for Inflector
impl RefUnwindSafe for Inflector
impl Send for Inflector
impl Sync for Inflector
impl Unpin for Inflector
impl UnsafeUnpin for Inflector
impl UnwindSafe for Inflector
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