Skip to main content

engage/generated/moon_sharp/interpreter/core_lib/
metatablemodule.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::system::object::{IObject, Object};
9
10    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/moon_sharp/interpreter/core_lib/metatablemodule/MetaTableModule.md"))]
11    #[::unity::class(namespace = "MoonSharp.Interpreter.CoreLib", name = "MetaTableModule")]
12    #[parent(crate::system::object::Object)]
13    pub struct MetaTableModule {}
14}
15
16#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule-types")]
17pub use __types::*;
18
19#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
20#[doc(hidden)]
21#[allow(non_snake_case, non_camel_case_types, clippy::too_many_arguments)]
22mod __MetaTableModule_unity_raw {
23    use super::*;
24    #[doc(hidden)]
25    #[allow(non_snake_case)]
26    pub mod __lookup_setmetatable {
27        use super::*;
28        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
29            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
30                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
31                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
32            ];
33            ::unity::lookup::method_info_on_class_with_signature(
34                <MetaTableModule as ::unity::ClassIdentity>::class(),
35                "setmetatable",
36                2,
37                param_types,
38                true,
39            )
40        });
41        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
42            match &*METHOD {
43                ::core::result::Result::Ok(mi) => *mi,
44                ::core::result::Result::Err(e) => {
45                    panic!(
46                        "method lookup failed: {}
47::{}
48: {}
49",
50                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
51                        "setmetatable",
52                        e
53                    )
54                },
55            }
56        }
57    }
58    #[doc(hidden)]
59    #[allow(non_snake_case)]
60    pub mod __lookup_getmetatable {
61        use super::*;
62        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
63            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
64                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
65                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
66            ];
67            ::unity::lookup::method_info_on_class_with_signature(
68                <MetaTableModule as ::unity::ClassIdentity>::class(),
69                "getmetatable",
70                2,
71                param_types,
72                true,
73            )
74        });
75        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
76            match &*METHOD {
77                ::core::result::Result::Ok(mi) => *mi,
78                ::core::result::Result::Err(e) => {
79                    panic!(
80                        "method lookup failed: {}
81::{}
82: {}
83",
84                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
85                        "getmetatable",
86                        e
87                    )
88                },
89            }
90        }
91    }
92    #[doc(hidden)]
93    #[allow(non_snake_case)]
94    pub mod __lookup_rawget {
95        use super::*;
96        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
97            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
98                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
99                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
100            ];
101            ::unity::lookup::method_info_on_class_with_signature(<MetaTableModule as ::unity::ClassIdentity>::class(), "rawget", 2, param_types, true)
102        });
103        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
104            match &*METHOD {
105                ::core::result::Result::Ok(mi) => *mi,
106                ::core::result::Result::Err(e) => {
107                    panic!(
108                        "method lookup failed: {}
109::{}
110: {}
111",
112                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
113                        "rawget",
114                        e
115                    )
116                },
117            }
118        }
119    }
120    #[doc(hidden)]
121    #[allow(non_snake_case)]
122    pub mod __lookup_rawset {
123        use super::*;
124        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
125            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
126                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
127                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
128            ];
129            ::unity::lookup::method_info_on_class_with_signature(<MetaTableModule as ::unity::ClassIdentity>::class(), "rawset", 2, param_types, true)
130        });
131        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
132            match &*METHOD {
133                ::core::result::Result::Ok(mi) => *mi,
134                ::core::result::Result::Err(e) => {
135                    panic!(
136                        "method lookup failed: {}
137::{}
138: {}
139",
140                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
141                        "rawset",
142                        e
143                    )
144                },
145            }
146        }
147    }
148    #[doc(hidden)]
149    #[allow(non_snake_case)]
150    pub mod __lookup_rawequal {
151        use super::*;
152        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
153            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
154                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
155                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
156            ];
157            ::unity::lookup::method_info_on_class_with_signature(
158                <MetaTableModule as ::unity::ClassIdentity>::class(),
159                "rawequal",
160                2,
161                param_types,
162                true,
163            )
164        });
165        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
166            match &*METHOD {
167                ::core::result::Result::Ok(mi) => *mi,
168                ::core::result::Result::Err(e) => {
169                    panic!(
170                        "method lookup failed: {}
171::{}
172: {}
173",
174                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
175                        "rawequal",
176                        e
177                    )
178                },
179            }
180        }
181    }
182    #[doc(hidden)]
183    #[allow(non_snake_case)]
184    pub mod __lookup_rawlen {
185        use super::*;
186        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
187            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
188                <crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext as ::unity::IlType>::il_type(),
189                <crate::moon_sharp::interpreter::callbackarguments::CallbackArguments as ::unity::IlType>::il_type(),
190            ];
191            ::unity::lookup::method_info_on_class_with_signature(<MetaTableModule as ::unity::ClassIdentity>::class(), "rawlen", 2, param_types, true)
192        });
193        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
194            match &*METHOD {
195                ::core::result::Result::Ok(mi) => *mi,
196                ::core::result::Result::Err(e) => {
197                    panic!(
198                        "method lookup failed: {}
199::{}
200: {}
201",
202                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
203                        "rawlen",
204                        e
205                    )
206                },
207            }
208        }
209    }
210    #[doc(hidden)]
211    #[allow(non_snake_case)]
212    pub mod __lookup_ctor {
213        use super::*;
214        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
215            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
216            ::unity::lookup::method_info_on_class_with_signature(<MetaTableModule as ::unity::ClassIdentity>::class(), ".ctor", 0, param_types, false)
217        });
218        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
219            match &*METHOD {
220                ::core::result::Result::Ok(mi) => *mi,
221                ::core::result::Result::Err(e) => {
222                    panic!(
223                        "method lookup failed: {}
224::{}
225: {}
226",
227                        <MetaTableModule as ::unity::ClassIdentity>::NAME,
228                        ".ctor",
229                        e
230                    )
231                },
232            }
233        }
234    }
235}
236
237#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
238impl MetaTableModule {
239    #[doc = "`setmetatable(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
240    pub fn setmetatable(
241        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
242        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
243    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
244        unsafe {
245            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_setmetatable::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
246(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
247        }
248    }
249
250    #[doc = "`getmetatable(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
251    pub fn getmetatable(
252        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
253        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
254    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
255        unsafe {
256            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_getmetatable::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
257(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
258        }
259    }
260
261    #[doc = "`rawget(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
262    pub fn rawget(
263        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
264        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
265    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
266        unsafe {
267            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_rawget::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
268(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
269        }
270    }
271
272    #[doc = "`rawset(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
273    pub fn rawset(
274        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
275        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
276    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
277        unsafe {
278            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_rawset::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
279(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
280        }
281    }
282
283    #[doc = "`rawequal(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
284    pub fn rawequal(
285        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
286        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
287    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
288        unsafe {
289            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_rawequal::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
290(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
291        }
292    }
293
294    #[doc = "`rawlen(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext, crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)` overload"]
295    pub fn rawlen(
296        execution_context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
297        args: impl ::core::convert::Into<crate::moon_sharp::interpreter::callbackarguments::CallbackArguments>,
298    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
299        unsafe {
300            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_rawlen::get_method_info().method_ptr,crate::moon_sharp::interpreter::dynvalue::DynValue;
301(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)::core::convert::Into::into(execution_context),(crate::moon_sharp::interpreter::callbackarguments::CallbackArguments)::core::convert::Into::into(args))
302        }
303    }
304}
305
306#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
307pub trait IMetaTableModuleMethods: IMetaTableModule {
308    #[doc = "`.ctor()` overload"]
309    fn ctor(self) -> () {
310        unsafe {
311            let __receiver = <MetaTableModule as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
312            ::unity::il2cpp_call!(__MetaTableModule_unity_raw::__lookup_ctor::get_method_info().method_ptr,();
313(MetaTableModule)__receiver)
314        }
315    }
316}
317
318#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
319impl<__T: IMetaTableModule> IMetaTableModuleMethods for __T {}
320
321#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
322impl MetaTableModule {
323    pub fn setmetatable_method_info() -> &'static ::unity::il2cpp::MethodInfo {
324        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
325    }
326
327    pub fn getmetatable_method_info() -> &'static ::unity::il2cpp::MethodInfo {
328        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
329    }
330
331    pub fn rawget_method_info() -> &'static ::unity::il2cpp::MethodInfo {
332        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
333    }
334
335    pub fn rawset_method_info() -> &'static ::unity::il2cpp::MethodInfo {
336        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
337    }
338
339    pub fn rawequal_method_info() -> &'static ::unity::il2cpp::MethodInfo {
340        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
341    }
342
343    pub fn rawlen_method_info() -> &'static ::unity::il2cpp::MethodInfo {
344        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
345    }
346
347    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
348        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
349    }
350}
351
352#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
353impl MetaTableModule {
354    #[doc = "`.ctor()` — no args"]
355    pub fn new() -> Self {
356        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
357            panic!(
358                "{}
359::{}
360 failed to instantiate",
361                ::core::stringify!(MetaTableModule),
362                ::core::stringify!(new),
363            )
364        });
365        <Self as IMetaTableModuleMethods>::ctor(this);
366        this
367    }
368}
369
370#[cfg(feature = "moon_sharp-interpreter-core_lib-metatablemodule")]
371#[doc(hidden)]
372pub mod prelude {
373    pub use super::{IMetaTableModule, IMetaTableModuleMethods, MetaTableModule};
374    pub use crate::system::object::IObject;
375    #[cfg(feature = "system-object")]
376    pub use crate::system::object::IObjectMethods;
377}