Trait ClassInfoMethods

Source
pub trait ClassInfoMethods: WxRustMethods {
    // Provided methods
    fn create_object(&self) -> Option<ObjectIsOwned<false>> { ... }
    fn get_base_class_name1(&self) -> *const c_void { ... }
    fn get_base_class_name2(&self) -> *const c_void { ... }
    fn get_class_name(&self) -> *const c_void { ... }
    fn get_size(&self) -> c_int { ... }
    fn is_dynamic(&self) -> bool { ... }
    fn is_kind_of<C: ClassInfoMethods>(&self, info: Option<&C>) -> bool { ... }
    fn find_class(class_name: &str) -> Option<ClassInfoIsOwned<false>> { ... }
}
Expand description

This trait represents C++ wxClassInfo class’s methods and inheritance.

See ClassInfoIsOwned documentation for the class usage.

Provided Methods§

Source

fn create_object(&self) -> Option<ObjectIsOwned<false>>

Creates an object of the appropriate kind.

See C++ wxClassInfo::CreateObject()’s documentation.

Source

fn get_base_class_name1(&self) -> *const c_void

Returns the name of the first base class (NULL if none).

See C++ wxClassInfo::GetBaseClassName1()’s documentation.

Source

fn get_base_class_name2(&self) -> *const c_void

Returns the name of the second base class (NULL if none).

See C++ wxClassInfo::GetBaseClassName2()’s documentation.

Source

fn get_class_name(&self) -> *const c_void

Returns the string form of the class name.

See C++ wxClassInfo::GetClassName()’s documentation.

Source

fn get_size(&self) -> c_int

Returns the size of the class.

See C++ wxClassInfo::GetSize()’s documentation.

Source

fn is_dynamic(&self) -> bool

Returns true if this class info can create objects of the associated class.

See C++ wxClassInfo::IsDynamic()’s documentation.

Source

fn is_kind_of<C: ClassInfoMethods>(&self, info: Option<&C>) -> bool

Returns true if this class is a kind of (inherits from) the given class.

See C++ wxClassInfo::IsKindOf()’s documentation.

Source

fn find_class(class_name: &str) -> Option<ClassInfoIsOwned<false>>

Finds the wxClassInfo object for a class with the given name.

See C++ wxClassInfo::FindClass()’s documentation.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<const OWNED: bool> ClassInfoMethods for ClassInfoIsOwned<OWNED>