[−][src]Enum cbindgen::RenameRule
A rule to apply to an identifier when generating bindings.
Variants
Do not apply any renaming. The default.
Converts the identifier to PascalCase and adds a context dependent prefix
Converts the identifier to lower case.
Converts the identifier to upper case.
Converts the identifier to PascalCase.
Converts the identifier to camelCase.
Converts the identifier to snake_case.
Converts the identifier to SCREAMING_SNAKE_CASE.
Converts the identifier to SCREAMING_SNAKE_CASE and prefixes enum variants with the enum name.
Methods
impl RenameRule
[src]
pub fn apply_to_pascal_case(self, text: &str, context: IdentifierType) -> String
[src]
Applies the rename rule to a string that is formatted in PascalCase.
pub fn apply_to_snake_case(self, text: &str, context: IdentifierType) -> String
[src]
Applies the rename rule to a string that is formatted in snake_case.
Trait Implementations
impl Clone for RenameRule
[src]
fn clone(&self) -> RenameRule
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for RenameRule
[src]
impl Default for RenameRule
[src]
fn default() -> RenameRule
[src]
impl Debug for RenameRule
[src]
impl FromStr for RenameRule
[src]
type Err = String
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<RenameRule, Self::Err>
[src]
impl<'de> Deserialize<'de> for RenameRule
[src]
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
Auto Trait Implementations
impl Send for RenameRule
impl Sync for RenameRule
impl Unpin for RenameRule
impl UnwindSafe for RenameRule
impl RefUnwindSafe for RenameRule
Blanket Implementations
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.
fn to_owned(&self) -> T
[src]
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 = !
The type returned in the event of a conversion error.
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,