Struct gdnative_core::init::InitHandle
source · [−]pub struct InitHandle { /* private fields */ }Expand description
A handle that can register new classes to the engine during initialization.
See godot_nativescript_init and
godot_init.
Implementations
sourceimpl InitHandle
impl InitHandle
sourcepub fn add_class<C>(self)where
C: NativeClassMethods + StaticallyNamed,
pub fn add_class<C>(self)where
C: NativeClassMethods + StaticallyNamed,
Registers a new class to the engine.
sourcepub fn add_tool_class<C>(self)where
C: NativeClassMethods + StaticallyNamed,
pub fn add_tool_class<C>(self)where
C: NativeClassMethods + StaticallyNamed,
Registers a new tool class to the engine.
sourcepub fn add_class_as<C>(self, name: String)where
C: NativeClassMethods,
pub fn add_class_as<C>(self, name: String)where
C: NativeClassMethods,
Registers a new class to the engine
If the type implements [StaticallyTyped], that name is ignored in favor of the
name provided at registration.
sourcepub fn add_tool_class_as<C>(self, name: String)where
C: NativeClassMethods,
pub fn add_tool_class_as<C>(self, name: String)where
C: NativeClassMethods,
Registers a new tool class to the engine
If the type implements [StaticallyTyped], that name is ignored in favor of the
name provided at registration.
Trait Implementations
sourceimpl Clone for InitHandle
impl Clone for InitHandle
sourcefn clone(&self) -> InitHandle
fn clone(&self) -> InitHandle
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for InitHandle
Auto Trait Implementations
impl RefUnwindSafe for InitHandle
impl !Send for InitHandle
impl !Sync for InitHandle
impl Unpin for InitHandle
impl UnwindSafe for InitHandle
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more