Struct opencv_binding_generator::Class
source · pub struct Class<'tu, 'ge> { /* private fields */ }
Implementations§
source§impl<'tu, 'ge> Class<'tu, 'ge>
impl<'tu, 'ge> Class<'tu, 'ge>
pub fn new(entity: Entity<'tu>, gen_env: &'ge GeneratorEnv<'tu>) -> Self
pub fn new_ext( entity: Entity<'tu>, custom_fullname: String, gen_env: &'ge GeneratorEnv<'tu> ) -> Self
pub fn can_be_simple(&self) -> bool
pub fn kind(&self) -> Kind
pub fn type_ref(&self) -> TypeRef<'tu, 'ge>
sourcepub fn as_template_specialization(&self) -> Option<Class<'tu, 'ge>>
pub fn as_template_specialization(&self) -> Option<Class<'tu, 'ge>>
Return template (Point_<T>
) if a class is a specific instance (Point_<int>
) of the template
pub fn is_template(&self) -> bool
pub fn is_simple(&self) -> bool
pub fn is_boxed(&self) -> bool
pub fn is_abstract(&self) -> bool
sourcepub fn is_polymorphic(&self) -> bool
pub fn is_polymorphic(&self) -> bool
True if class has virtual methods
pub fn is_trait(&self) -> bool
sourcepub fn as_enum(&self) -> Option<Enum<'tu>>
pub fn as_enum(&self) -> Option<Enum<'tu>>
Special case of an empty class with only an anonymous enum inside (e.g. DrawLinesMatchesFlags)
sourcepub fn has_explicit_clone(&self) -> bool
pub fn has_explicit_clone(&self) -> bool
Class has an explicit method named clone()
sourcepub fn has_implicit_clone(&self) -> bool
pub fn has_implicit_clone(&self) -> bool
Class is simple (i.e. constructor-copiable in C++), but can’t be simple in Rust
pub fn has_virtual_destructor(&self) -> bool
pub fn has_bases(&self) -> bool
pub fn bases(&self) -> Vec<Class<'tu, 'ge>>
pub fn all_bases(&self) -> HashSet<Class<'tu, 'ge>>
pub fn has_descendants(&self) -> bool
pub fn descendants(&self) -> impl Iterator<Item = Class<'tu, 'ge>>
pub fn has_methods(&self) -> bool
pub fn for_each_method( &self, predicate: impl FnMut(Func<'tu, 'ge>) -> WalkAction ) -> WalkResult
pub fn methods( &self, constness_filter: Option<Constness> ) -> Vec<Func<'tu, 'ge>>
pub fn has_fields(&self) -> bool
pub fn for_each_field( &self, predicate: impl FnMut(Field<'tu, 'ge>) -> WalkAction ) -> WalkResult
pub fn fields(&self) -> Vec<Field<'tu, 'ge>>
pub fn consts(&self) -> Vec<Const<'tu>>
pub fn field_methods<'f>( &self, fields: impl Iterator<Item = &'f Field<'tu, 'ge>>, constness_filter: Option<Constness> ) -> Vec<Func<'tu, 'ge>>where 'tu: 'f, 'ge: 'f,
pub fn is_definition(&self) -> bool
pub fn generated_types(&self) -> Vec<GeneratedType<'tu, 'ge>>
Trait Implementations§
source§impl Element for Class<'_, '_>
impl Element for Class<'_, '_>
source§fn is_excluded(&self) -> bool
fn is_excluded(&self) -> bool
true if an element shouldn’t be generated
source§fn is_ignored(&self) -> bool
fn is_ignored(&self) -> bool
true if there shouldn’t be any references to that element