Skip to main content

engage/generated/app/
mapbinder.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "app-mapbinder-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::{
9        app::singletonclass_1::{ISingletonClass_1, SingletonClass_1},
10        system::object::{IObject, Object},
11    };
12
13    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/app/mapbinder/MapBinder.md"))]
14    #[::unity::class(namespace = "App", name = "MapBinder")]
15    #[parent(crate::app::singletonclass_1::SingletonClass_1<crate::app::mapbinder::MapBinder>)]
16    pub struct MapBinder {}
17}
18
19#[cfg(feature = "app-mapbinder-types")]
20pub use __types::*;
21
22#[cfg(feature = "app-mapbinder")]
23pub trait IMapBinderMethods: IMapBinder {
24    #[doc = "`OnBind()` overload"]
25    fn on_bind(self) -> () {
26        unsafe {
27            let __receiver = <MapBinder as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
28            {
29                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
30                let __vi = *__vt.get(9usize).unwrap_or_else(|| {
31                    panic!(
32                        "unity: virtual slot {}
33 out of range (vtable len {}
34) on the runtime class behind {}
35 (method `{}
36`)",
37                        9usize,
38                        __vt.len(),
39                        <MapBinder as ::unity::ClassIdentity>::NAME,
40                        "OnBind",
41                    )
42                });
43                let __inner: extern "C" fn(MapBinder, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
44                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
45                __inner(__receiver, __mi)
46            }
47        }
48    }
49    #[doc = "`OnUnbind()` overload"]
50    fn on_unbind(self) -> () {
51        unsafe {
52            let __receiver = <MapBinder as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
53            {
54                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
55                let __vi = *__vt.get(10usize).unwrap_or_else(|| {
56                    panic!(
57                        "unity: virtual slot {}
58 out of range (vtable len {}
59) on the runtime class behind {}
60 (method `{}
61`)",
62                        10usize,
63                        __vt.len(),
64                        <MapBinder as ::unity::ClassIdentity>::NAME,
65                        "OnUnbind",
66                    )
67                });
68                let __inner: extern "C" fn(MapBinder, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
69                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
70                __inner(__receiver, __mi)
71            }
72        }
73    }
74    #[doc = "`.ctor()` overload"]
75    fn ctor(self) -> () {
76        unsafe {
77            let __receiver = <MapBinder as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
78            ::unity::il2cpp_call!((::unity::module_base()+0x299a0a0usize)as*mut u8,();
79(MapBinder)__receiver)
80        }
81    }
82}
83
84#[cfg(feature = "app-mapbinder")]
85impl<__T: IMapBinder> IMapBinderMethods for __T {}
86
87#[cfg(feature = "app-mapbinder")]
88impl MapBinder {
89    pub fn on_bind_method_info() -> &'static ::unity::il2cpp::MethodInfo {
90        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
91    }
92
93    pub fn on_unbind_method_info() -> &'static ::unity::il2cpp::MethodInfo {
94        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
95    }
96
97    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
98        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
99    }
100}
101
102#[cfg(feature = "app-mapbinder")]
103impl MapBinder {
104    #[doc = "Direct (non-virtual) call to `MapBinder`'s own `OnBind`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
105    pub unsafe fn on_bind(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
106        let __mi = Self::on_bind_method_info();
107        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
108        __inner(this.into(), ::core::option::Option::None)
109    }
110
111    #[doc = "Direct (non-virtual) call to `MapBinder`'s own `OnUnbind`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
112    pub unsafe fn on_unbind(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
113        let __mi = Self::on_unbind_method_info();
114        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
115        __inner(this.into(), ::core::option::Option::None)
116    }
117}
118
119#[cfg(feature = "app-mapbinder")]
120impl MapBinder {
121    #[doc = "`.ctor()` — no args"]
122    pub fn new() -> Self {
123        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
124            panic!(
125                "{}
126::{}
127 failed to instantiate",
128                ::core::stringify!(MapBinder),
129                ::core::stringify!(new),
130            )
131        });
132        <Self as IMapBinderMethods>::ctor(this);
133        this
134    }
135}
136
137#[cfg(feature = "app-mapbinder")]
138#[doc(hidden)]
139pub mod prelude {
140    pub use super::{IMapBinder, IMapBinderMethods, MapBinder};
141    #[cfg(feature = "app-singletonclass_1")]
142    pub use crate::app::singletonclass_1::ISingletonClass_1Methods;
143    #[cfg(feature = "system-object")]
144    pub use crate::system::object::IObjectMethods;
145    pub use crate::{app::singletonclass_1::ISingletonClass_1, system::object::IObject};
146}