Module gdnative_core::object
source · Expand description
Provides types to interact with the Godot Object
class hierarchy
This module contains wrappers and helpers to interact with Godot objects.
In Godot, classes stand in an inheritance relationship, with the root at Object
.
If you are looking for how to manage user-defined types (native scripts),
check out the export
module.
Modules
Various traits to verify memory policy, ownership policy or lifetime bounds
Marker types to express the memory management method of Godot types.
Typestates to express ownership and thread safety of Godot types.
Structs
A persistent reference to a GodotObject with a rust NativeClass attached.
Represents an explicit null reference in method arguments. This works around type inference
issues with
Option
. You may create Null
s with Null::null
or GodotObject::null
.An opaque struct representing Godot objects. This should never be created on the stack.
A polymorphic smart pointer for Godot objects whose behavior changes depending on the
memory management method of the underlying type and the thread access status.
A reference to a GodotObject with a rust NativeClass attached that is assumed safe during
a certain lifetime.
A temporary safe pointer to Godot objects that tracks thread access status.
TRef
can be
coerced into bare references with Deref
.Traits
Trait for safe conversion from Godot object references into API method arguments. This is
a sealed trait with no public interface.
Trait for safe conversion from Godot object references into Variant. This is
a sealed trait with no public interface.
Trait for Godot API objects. This trait is sealed, and implemented for generated wrapper
types.
GodotObjects that have a zero argument constructor.
A trait for incrementing the reference count to a Godot object.
Manually managed Godot classes implementing
queue_free
. This trait has no public
interface. See Ref::queue_free
.Marker trait for API types that are subclasses of another type. This trait is implemented
by the bindings generator, and has no public interface. Users should not attempt to
implement this trait.