Struct cbindgen::StructConfig
source · pub struct StructConfig {Show 13 fields
pub rename_fields: RenameRule,
pub derive_constructor: bool,
pub derive_eq: bool,
pub derive_neq: bool,
pub derive_lt: bool,
pub derive_lte: bool,
pub derive_gt: bool,
pub derive_gte: bool,
pub derive_ostream: bool,
pub associated_constants_in_body: bool,
pub must_use: Option<String>,
pub deprecated: Option<String>,
pub deprecated_with_note: Option<String>,
}Expand description
Settings to apply to generated structs.
Fields§
§rename_fields: RenameRuleThe rename rule to apply to the name of struct fields
derive_constructor: boolWhether to generate a constructor for the struct (which takes arguments to initialize all the members)
derive_eq: boolWhether to generate a piecewise equality operator
derive_neq: boolWhether to generate a piecewise inequality operator
derive_lt: boolWhether to generate a less than operator on structs with one field
derive_lte: boolWhether to generate a less than or equal to operator on structs with one field
derive_gt: boolWhether to generate a greater than operator on structs with one field
derive_gte: boolWhether to generate a greater than or equal to operator on structs with one field
derive_ostream: boolWhether to generate a ostream serializer for the struct
associated_constants_in_body: boolWhether associated constants should be in the body. Only applicable to non-transparent structs, and in C++-only.
must_use: Option<String>The way to annotate this struct as #[must_use].
deprecated: Option<String>The way to annotation this function as #[deprecated] without notes
deprecated_with_note: Option<String>The way to annotation this function as #[deprecated] with notes
Trait Implementations§
source§impl Clone for StructConfig
impl Clone for StructConfig
source§fn clone(&self) -> StructConfig
fn clone(&self) -> StructConfig
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more