engage/generated/system/reflection/
runtimeconstructorinfo.rs1#[cfg(feature = "system-reflection-runtimeconstructorinfo-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::system::{
9 object::{IObject, Object},
10 reflection::{
11 constructorinfo::{ConstructorInfo, IConstructorInfo},
12 memberinfo::{IMemberInfo, MemberInfo},
13 methodbase::{IMethodBase, MethodBase},
14 },
15 };
16
17 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/reflection/runtimeconstructorinfo/RuntimeConstructorInfo.md"))]
18 #[::unity::class(namespace = "System.Reflection", name = "RuntimeConstructorInfo")]
19 #[parent(crate::system::reflection::constructorinfo::ConstructorInfo)]
20 pub struct RuntimeConstructorInfo {}
21}
22
23#[cfg(feature = "system-reflection-runtimeconstructorinfo-types")]
24pub use __types::*;
25
26#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
27pub trait IRuntimeConstructorInfoMethods: IRuntimeConstructorInfo {
28 #[doc = "`get_Module()` overload"]
29 fn get_module(self) -> crate::system::reflection::module::Module {
30 unsafe {
31 let __receiver =
32 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
33 {
34 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
35 let __vi = *__vt.get(15usize).unwrap_or_else(|| {
36 panic!(
37 "unity: virtual slot {}
38 out of range (vtable len {}
39) on the runtime class behind {}
40 (method `{}
41`)",
42 15usize,
43 __vt.len(),
44 <RuntimeConstructorInfo as ::unity::ClassIdentity>::NAME,
45 "get_Module",
46 )
47 });
48 let __inner: extern "C" fn(RuntimeConstructorInfo, ::unity::OptionalMethod) -> crate::system::reflection::module::Module =
49 ::core::mem::transmute(__vi.method_ptr);
50 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
51 __inner(__receiver, __mi)
52 }
53 }
54 }
55 #[doc = "`GetRuntimeModule()` overload"]
56 fn get_runtime_module(self) -> crate::system::reflection::runtimemodule::RuntimeModule {
57 unsafe {
58 let __receiver =
59 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
60 ::unity::il2cpp_call!((::unity::module_base()+0x2fd3bd0usize)as*mut u8,crate::system::reflection::runtimemodule::RuntimeModule;
61(RuntimeConstructorInfo)__receiver)
62 }
63 }
64 #[doc = "`get_BindingFlags()` overload"]
65 fn get_binding_flags(self) -> crate::system::reflection::bindingflags::BindingFlags {
66 unsafe {
67 let __receiver =
68 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
69 ::unity::il2cpp_call!((::unity::module_base()+0x2fd3c60usize)as*mut u8,crate::system::reflection::bindingflags::BindingFlags;
70(RuntimeConstructorInfo)__receiver)
71 }
72 }
73 #[doc = "`get_ReflectedTypeInternal()` overload"]
74 fn get_reflected_type_internal(self) -> crate::system::runtimetype::RuntimeType {
75 unsafe {
76 let __receiver =
77 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
78 ::unity::il2cpp_call!((::unity::module_base()+0x2fd3c70usize)as*mut u8,crate::system::runtimetype::RuntimeType;
79(RuntimeConstructorInfo)__receiver)
80 }
81 }
82 #[doc = "`SerializationToString()` overload"]
83 fn serialization_to_string(self) -> ::unity::Il2CppString {
84 unsafe {
85 let __receiver =
86 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
87 ::unity::il2cpp_call!((::unity::module_base()+0x2fd3e50usize)as*mut u8, ::unity::Il2CppString;
88(RuntimeConstructorInfo)__receiver)
89 }
90 }
91 #[doc = "`.ctor()` overload"]
92 fn ctor(self) -> () {
93 unsafe {
94 let __receiver =
95 <RuntimeConstructorInfo as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
96 ::unity::il2cpp_call!((::unity::module_base()+0x2fd3fb0usize)as*mut u8,();
97(RuntimeConstructorInfo)__receiver)
98 }
99 }
100}
101
102#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
103impl<__T: IRuntimeConstructorInfo> IRuntimeConstructorInfoMethods for __T {}
104
105#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
106impl RuntimeConstructorInfo {
107 pub fn get_module_method_info() -> &'static ::unity::il2cpp::MethodInfo {
108 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
109 }
110
111 pub fn get_runtime_module_method_info() -> &'static ::unity::il2cpp::MethodInfo {
112 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
113 }
114
115 pub fn get_binding_flags_method_info() -> &'static ::unity::il2cpp::MethodInfo {
116 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
117 }
118
119 pub fn get_reflected_type_internal_method_info() -> &'static ::unity::il2cpp::MethodInfo {
120 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
121 }
122
123 pub fn serialization_to_string_method_info() -> &'static ::unity::il2cpp::MethodInfo {
124 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
125 }
126
127 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
128 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
129 }
130}
131
132#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
133impl RuntimeConstructorInfo {
134 #[doc = "Direct (non-virtual) call to `RuntimeConstructorInfo`'s own `get_Module`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
135 pub unsafe fn get_module(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::reflection::module::Module {
136 let __mi = Self::get_module_method_info();
137 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::reflection::module::Module =
138 ::core::mem::transmute(__mi.method_ptr);
139 __inner(this.into(), ::core::option::Option::None)
140 }
141}
142
143#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
144impl RuntimeConstructorInfo {
145 #[doc = "`.ctor()` — no args"]
146 pub fn new() -> Self {
147 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
148 panic!(
149 "{}
150::{}
151 failed to instantiate",
152 ::core::stringify!(RuntimeConstructorInfo),
153 ::core::stringify!(new),
154 )
155 });
156 <Self as IRuntimeConstructorInfoMethods>::ctor(this);
157 this
158 }
159}
160
161#[cfg(feature = "system-reflection-runtimeconstructorinfo")]
162#[doc(hidden)]
163pub mod prelude {
164 pub use super::{IRuntimeConstructorInfo, IRuntimeConstructorInfoMethods, RuntimeConstructorInfo};
165 #[cfg(feature = "system-object")]
166 pub use crate::system::object::IObjectMethods;
167 #[cfg(feature = "system-reflection-constructorinfo")]
168 pub use crate::system::reflection::constructorinfo::IConstructorInfoMethods;
169 #[cfg(feature = "system-reflection-memberinfo")]
170 pub use crate::system::reflection::memberinfo::IMemberInfoMethods;
171 #[cfg(feature = "system-reflection-methodbase")]
172 pub use crate::system::reflection::methodbase::IMethodBaseMethods;
173 pub use crate::system::{
174 object::IObject,
175 reflection::{constructorinfo::IConstructorInfo, memberinfo::IMemberInfo, methodbase::IMethodBase},
176 };
177}