Struct GdextBuild
pub struct GdextBuild;
Expand description
Provides meta-information about the library and the Godot version in use.
Implementations§
§impl GdextBuild
impl GdextBuild
pub const fn godot_static_version_string() -> &'static str
pub const fn godot_static_version_string() -> &'static str
Godot version against which gdext was compiled.
Example format: v4.0.stable.official
pub const fn godot_static_version_triple() -> (u8, u8, u8)
pub const fn godot_static_version_triple() -> (u8, u8, u8)
Godot version against which gdext was compiled, as (major, minor, patch)
triple.
pub fn godot_runtime_version_string() -> String
pub fn godot_runtime_version_string() -> String
Version of the Godot engine which loaded gdext via GDExtension binding.
pub fn godot_runtime_version_triple() -> (u8, u8, u8)
pub fn godot_runtime_version_triple() -> (u8, u8, u8)
Version of the Godot engine which loaded gdext via GDExtension binding, as
(major, minor, patch)
triple.
pub fn before_api(major_minor: &str) -> bool
pub fn before_api(major_minor: &str) -> bool
For a string "4.x"
, returns true
if the current Godot version is strictly less than 4.x.
Runtime equivalent of #[cfg(before_api = "4.x")]
.
§Panics
On bad input.
Auto Trait Implementations§
impl Freeze for GdextBuild
impl RefUnwindSafe for GdextBuild
impl Send for GdextBuild
impl Sync for GdextBuild
impl Unpin for GdextBuild
impl UnwindSafe for GdextBuild
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more