1#[cfg(feature = "system-reflection-monomethod-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 memberinfo::{IMemberInfo, MemberInfo},
12 methodbase::{IMethodBase, MethodBase},
13 methodinfo::{IMethodInfo, MethodInfo},
14 runtimemethodinfo::{IRuntimeMethodInfo, RuntimeMethodInfo},
15 },
16 };
17
18 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/reflection/monomethod/MonoMethod.md"))]
19 #[::unity::class(namespace = "System.Reflection", name = "MonoMethod")]
20 #[parent(crate::system::reflection::runtimemethodinfo::RuntimeMethodInfo)]
21 pub struct MonoMethod {
22 #[offset(16)]
23 #[rename(name = "mhandle")]
24 pub mhandle: ::unity::IntPtr,
25 #[offset(24)]
26 #[rename(name = "name")]
27 pub name: ::unity::Il2CppString,
28 #[offset(32)]
29 #[rename(name = "reftype")]
30 pub reftype: ::unity::SystemType,
31 }
32}
33
34#[cfg(feature = "system-reflection-monomethod-types")]
35pub use __types::*;
36
37#[cfg(feature = "system-reflection-monomethod")]
38impl MonoMethod {
39 #[doc = "`get_name(crate::system::reflection::methodbase::MethodBase)` overload"]
40 pub fn get_name(method: impl ::core::convert::Into<crate::system::reflection::methodbase::MethodBase>) -> ::unity::Il2CppString {
41 unsafe {
42 ::unity::il2cpp_call!((::unity::module_base()+0x337c030usize)as*mut u8, ::unity::Il2CppString;
43(crate::system::reflection::methodbase::MethodBase)::core::convert::Into::into(method))
44 }
45 }
46
47 #[doc = "`get_base_method(crate::system::reflection::monomethod::MonoMethod, bool)` overload"]
48 pub fn get_base_method(
49 method: impl ::core::convert::Into<crate::system::reflection::monomethod::MonoMethod>,
50 definition: impl ::core::convert::Into<bool>,
51 ) -> crate::system::reflection::monomethod::MonoMethod {
52 unsafe {
53 ::unity::il2cpp_call!((::unity::module_base()+0x33814c0usize)as*mut u8,crate::system::reflection::monomethod::MonoMethod;
54(crate::system::reflection::monomethod::MonoMethod)::core::convert::Into::into(method),(bool)::core::convert::Into::into(definition))
55 }
56 }
57
58 #[doc = "`get_core_clr_security_level()` overload"]
59 pub fn get_core_clr_security_level() -> i32 {
60 unsafe {
61 ::unity::il2cpp_call!((::unity::module_base()+0x3382010usize)as*mut u8,i32;
62 )
63 }
64 }
65}
66
67#[cfg(feature = "system-reflection-monomethod")]
68pub trait IMonoMethodMethods: IMonoMethod {
69 #[doc = "`.ctor()` overload"]
70 fn ctor(self) -> () {
71 unsafe {
72 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
73 ::unity::il2cpp_call!((::unity::module_base()+0x33814b0usize)as*mut u8,();
74(MonoMethod)__receiver)
75 }
76 }
77 #[doc = "`GetBaseMethod()` overload"]
78 fn get_base_method_2(self) -> crate::system::reflection::methodinfo::MethodInfo {
79 unsafe {
80 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
81 {
82 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
83 let __vi = *__vt.get(49usize).unwrap_or_else(|| {
84 panic!(
85 "unity: virtual slot {}
86 out of range (vtable len {}
87) on the runtime class behind {}
88 (method `{}
89`)",
90 49usize,
91 __vt.len(),
92 <MonoMethod as ::unity::ClassIdentity>::NAME,
93 "GetBaseMethod",
94 )
95 });
96 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> crate::system::reflection::methodinfo::MethodInfo =
97 ::core::mem::transmute(__vi.method_ptr);
98 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
99 __inner(__receiver, __mi)
100 }
101 }
102 }
103 #[doc = "`get_ReturnType()` overload"]
104 fn get_return_type(self) -> ::unity::SystemType {
105 unsafe {
106 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
107 {
108 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
109 let __vi = *__vt.get(44usize).unwrap_or_else(|| {
110 panic!(
111 "unity: virtual slot {}
112 out of range (vtable len {}
113) on the runtime class behind {}
114 (method `{}
115`)",
116 44usize,
117 __vt.len(),
118 <MonoMethod as ::unity::ClassIdentity>::NAME,
119 "get_ReturnType",
120 )
121 });
122 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__vi.method_ptr);
123 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
124 __inner(__receiver, __mi)
125 }
126 }
127 }
128 #[doc = "`GetMethodImplementationFlags()` overload"]
129 fn get_method_implementation_flags(self) -> crate::system::reflection::methodimplattributes::MethodImplAttributes {
130 unsafe {
131 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
132 {
133 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
134 let __vi = *__vt.get(18usize).unwrap_or_else(|| {
135 panic!(
136 "unity: virtual slot {}
137 out of range (vtable len {}
138) on the runtime class behind {}
139 (method `{}
140`)",
141 18usize,
142 __vt.len(),
143 <MonoMethod as ::unity::ClassIdentity>::NAME,
144 "GetMethodImplementationFlags",
145 )
146 });
147 let __inner: extern "C" fn(
148 MonoMethod,
149 ::unity::OptionalMethod,
150 ) -> crate::system::reflection::methodimplattributes::MethodImplAttributes = ::core::mem::transmute(__vi.method_ptr);
151 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
152 __inner(__receiver, __mi)
153 }
154 }
155 }
156 #[doc = "`GetParameters()` overload"]
157 fn get_parameters(self) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> {
158 unsafe {
159 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
160 {
161 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
162 let __vi = *__vt.get(17usize).unwrap_or_else(|| {
163 panic!(
164 "unity: virtual slot {}
165 out of range (vtable len {}
166) on the runtime class behind {}
167 (method `{}
168`)",
169 17usize,
170 __vt.len(),
171 <MonoMethod as ::unity::ClassIdentity>::NAME,
172 "GetParameters",
173 )
174 });
175 let __inner: extern "C" fn(
176 MonoMethod,
177 ::unity::OptionalMethod,
178 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> = ::core::mem::transmute(__vi.method_ptr);
179 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
180 __inner(__receiver, __mi)
181 }
182 }
183 }
184 #[doc = "`GetParametersInternal()` overload"]
185 fn get_parameters_internal(self) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> {
186 unsafe {
187 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
188 {
189 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
190 let __vi = *__vt.get(42usize).unwrap_or_else(|| {
191 panic!(
192 "unity: virtual slot {}
193 out of range (vtable len {}
194) on the runtime class behind {}
195 (method `{}
196`)",
197 42usize,
198 __vt.len(),
199 <MonoMethod as ::unity::ClassIdentity>::NAME,
200 "GetParametersInternal",
201 )
202 });
203 let __inner: extern "C" fn(
204 MonoMethod,
205 ::unity::OptionalMethod,
206 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> = ::core::mem::transmute(__vi.method_ptr);
207 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
208 __inner(__receiver, __mi)
209 }
210 }
211 }
212 #[doc = "`GetParametersCount()` overload"]
213 fn get_parameters_count(self) -> i32 {
214 unsafe {
215 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
216 {
217 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
218 let __vi = *__vt.get(43usize).unwrap_or_else(|| {
219 panic!(
220 "unity: virtual slot {}
221 out of range (vtable len {}
222) on the runtime class behind {}
223 (method `{}
224`)",
225 43usize,
226 __vt.len(),
227 <MonoMethod as ::unity::ClassIdentity>::NAME,
228 "GetParametersCount",
229 )
230 });
231 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__vi.method_ptr);
232 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
233 __inner(__receiver, __mi)
234 }
235 }
236 }
237 #[doc = "`get_Attributes()` overload"]
238 fn get_attributes(self) -> crate::system::reflection::methodattributes::MethodAttributes {
239 unsafe {
240 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
241 {
242 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
243 let __vi = *__vt.get(20usize).unwrap_or_else(|| {
244 panic!(
245 "unity: virtual slot {}
246 out of range (vtable len {}
247) on the runtime class behind {}
248 (method `{}
249`)",
250 20usize,
251 __vt.len(),
252 <MonoMethod as ::unity::ClassIdentity>::NAME,
253 "get_Attributes",
254 )
255 });
256 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> crate::system::reflection::methodattributes::MethodAttributes =
257 ::core::mem::transmute(__vi.method_ptr);
258 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
259 __inner(__receiver, __mi)
260 }
261 }
262 }
263 #[doc = "`get_CallingConvention()` overload"]
264 fn get_calling_convention(self) -> crate::system::reflection::callingconventions::CallingConventions {
265 unsafe {
266 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
267 {
268 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
269 let __vi = *__vt.get(22usize).unwrap_or_else(|| {
270 panic!(
271 "unity: virtual slot {}
272 out of range (vtable len {}
273) on the runtime class behind {}
274 (method `{}
275`)",
276 22usize,
277 __vt.len(),
278 <MonoMethod as ::unity::ClassIdentity>::NAME,
279 "get_CallingConvention",
280 )
281 });
282 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> crate::system::reflection::callingconventions::CallingConventions =
283 ::core::mem::transmute(__vi.method_ptr);
284 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
285 __inner(__receiver, __mi)
286 }
287 }
288 }
289 #[doc = "`get_ReflectedType()` overload"]
290 fn get_reflected_type(self) -> ::unity::SystemType {
291 unsafe {
292 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
293 {
294 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
295 let __vi = *__vt.get(9usize).unwrap_or_else(|| {
296 panic!(
297 "unity: virtual slot {}
298 out of range (vtable len {}
299) on the runtime class behind {}
300 (method `{}
301`)",
302 9usize,
303 __vt.len(),
304 <MonoMethod as ::unity::ClassIdentity>::NAME,
305 "get_ReflectedType",
306 )
307 });
308 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__vi.method_ptr);
309 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
310 __inner(__receiver, __mi)
311 }
312 }
313 }
314 #[doc = "`get_DeclaringType()` overload"]
315 fn get_declaring_type(self) -> ::unity::SystemType {
316 unsafe {
317 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
318 {
319 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
320 let __vi = *__vt.get(8usize).unwrap_or_else(|| {
321 panic!(
322 "unity: virtual slot {}
323 out of range (vtable len {}
324) on the runtime class behind {}
325 (method `{}
326`)",
327 8usize,
328 __vt.len(),
329 <MonoMethod as ::unity::ClassIdentity>::NAME,
330 "get_DeclaringType",
331 )
332 });
333 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__vi.method_ptr);
334 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
335 __inner(__receiver, __mi)
336 }
337 }
338 }
339 #[doc = "`get_Name()` overload"]
340 fn get_name_2(self) -> ::unity::Il2CppString {
341 unsafe {
342 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
343 {
344 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
345 let __vi = *__vt.get(7usize).unwrap_or_else(|| {
346 panic!(
347 "unity: virtual slot {}
348 out of range (vtable len {}
349) on the runtime class behind {}
350 (method `{}
351`)",
352 7usize,
353 __vt.len(),
354 <MonoMethod as ::unity::ClassIdentity>::NAME,
355 "get_Name",
356 )
357 });
358 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__vi.method_ptr);
359 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
360 __inner(__receiver, __mi)
361 }
362 }
363 }
364 #[doc = "`IsDefined(::unity::SystemType, bool)` overload"]
365 fn is_defined(self, attribute_type: impl ::core::convert::Into<::unity::SystemType>, inherit: impl ::core::convert::Into<bool>) -> bool {
366 unsafe {
367 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
368 {
369 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
370 let __vi = *__vt.get(12usize).unwrap_or_else(|| {
371 panic!(
372 "unity: virtual slot {}
373 out of range (vtable len {}
374) on the runtime class behind {}
375 (method `{}
376`)",
377 12usize,
378 __vt.len(),
379 <MonoMethod as ::unity::ClassIdentity>::NAME,
380 "IsDefined",
381 )
382 });
383 let __inner: extern "C" fn(MonoMethod, ::unity::SystemType, bool, ::unity::OptionalMethod) -> bool =
384 ::core::mem::transmute(__vi.method_ptr);
385 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
386 __inner(
387 __receiver,
388 ::core::convert::Into::into(attribute_type),
389 ::core::convert::Into::into(inherit),
390 __mi,
391 )
392 }
393 }
394 }
395 #[doc = "`GetCustomAttributes(bool)` overload"]
396 fn get_custom_attributes(self, inherit: impl ::core::convert::Into<bool>) -> ::unity::Array<crate::system::object::Object> {
397 unsafe {
398 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
399 {
400 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
401 let __vi = *__vt.get(10usize).unwrap_or_else(|| {
402 panic!(
403 "unity: virtual slot {}
404 out of range (vtable len {}
405) on the runtime class behind {}
406 (method `{}
407`)",
408 10usize,
409 __vt.len(),
410 <MonoMethod as ::unity::ClassIdentity>::NAME,
411 "GetCustomAttributes",
412 )
413 });
414 let __inner: extern "C" fn(MonoMethod, bool, ::unity::OptionalMethod) -> ::unity::Array<crate::system::object::Object> =
415 ::core::mem::transmute(__vi.method_ptr);
416 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
417 __inner(__receiver, ::core::convert::Into::into(inherit), __mi)
418 }
419 }
420 }
421 #[doc = "`GetCustomAttributes(::unity::SystemType, bool)` overload"]
422 fn get_custom_attributes_2(
423 self,
424 attribute_type: impl ::core::convert::Into<::unity::SystemType>,
425 inherit: impl ::core::convert::Into<bool>,
426 ) -> ::unity::Array<crate::system::object::Object> {
427 unsafe {
428 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
429 {
430 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
431 let __vi = *__vt.get(11usize).unwrap_or_else(|| {
432 panic!(
433 "unity: virtual slot {}
434 out of range (vtable len {}
435) on the runtime class behind {}
436 (method `{}
437`)",
438 11usize,
439 __vt.len(),
440 <MonoMethod as ::unity::ClassIdentity>::NAME,
441 "GetCustomAttributes",
442 )
443 });
444 let __inner: extern "C" fn(
445 MonoMethod,
446 ::unity::SystemType,
447 bool,
448 ::unity::OptionalMethod,
449 ) -> ::unity::Array<crate::system::object::Object> = ::core::mem::transmute(__vi.method_ptr);
450 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
451 __inner(
452 __receiver,
453 ::core::convert::Into::into(attribute_type),
454 ::core::convert::Into::into(inherit),
455 __mi,
456 )
457 }
458 }
459 }
460 #[doc = "`GetPInvoke(*mutcrate::system::reflection::pinvokeattributes::PInvokeAttributes, *mut::unity::Il2CppString, *mut::unity::Il2CppString)` overload"]
461 fn get_p_invoke(
462 self,
463 ) -> (
464 crate::system::reflection::pinvokeattributes::PInvokeAttributes,
465 ::unity::Il2CppString,
466 ::unity::Il2CppString,
467 ) {
468 unsafe {
469 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
470 let mut __out_0 = ::core::mem::MaybeUninit::<crate::system::reflection::pinvokeattributes::PInvokeAttributes>::uninit();
471 let mut __out_1 = ::core::mem::MaybeUninit::<::unity::Il2CppString>::uninit();
472 let mut __out_2 = ::core::mem::MaybeUninit::<::unity::Il2CppString>::uninit();
473 ::unity::il2cpp_call!((::unity::module_base()+0x3381a90usize)as*mut u8,();
474(MonoMethod)__receiver,(*mut crate::system::reflection::pinvokeattributes::PInvokeAttributes)__out_0.as_mut_ptr(),(*mut::unity::Il2CppString)__out_1.as_mut_ptr(),(*mut::unity::Il2CppString)__out_2.as_mut_ptr());
475 (__out_0.assume_init(), __out_1.assume_init(), __out_2.assume_init())
476 }
477 }
478 #[doc = "`GetPseudoCustomAttributes()` overload"]
479 fn get_pseudo_custom_attributes(self) -> ::unity::Array<crate::system::object::Object> {
480 unsafe {
481 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
482 ::unity::il2cpp_call!((::unity::module_base()+0x337d8a0usize)as*mut u8, ::unity::Array<crate::system::object::Object> ;
483(MonoMethod)__receiver)
484 }
485 }
486 #[doc = "`MakeGenericMethod(::unity::Array<::unity::SystemType>)` overload"]
487 fn make_generic_method(
488 self,
489 method_instantiation: impl ::core::convert::Into<::unity::Array<::unity::SystemType>>,
490 ) -> crate::system::reflection::methodinfo::MethodInfo {
491 unsafe {
492 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
493 {
494 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
495 let __vi = *__vt.get(46usize).unwrap_or_else(|| {
496 panic!(
497 "unity: virtual slot {}
498 out of range (vtable len {}
499) on the runtime class behind {}
500 (method `{}
501`)",
502 46usize,
503 __vt.len(),
504 <MonoMethod as ::unity::ClassIdentity>::NAME,
505 "MakeGenericMethod",
506 )
507 });
508 let __inner: extern "C" fn(
509 MonoMethod,
510 ::unity::Array<::unity::SystemType>,
511 ::unity::OptionalMethod,
512 ) -> crate::system::reflection::methodinfo::MethodInfo = ::core::mem::transmute(__vi.method_ptr);
513 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
514 __inner(__receiver, ::core::convert::Into::into(method_instantiation), __mi)
515 }
516 }
517 }
518 #[doc = "`MakeGenericMethod_impl(::unity::Array<::unity::SystemType>)` overload"]
519 fn make_generic_method_impl(
520 self,
521 types: impl ::core::convert::Into<::unity::Array<::unity::SystemType>>,
522 ) -> crate::system::reflection::methodinfo::MethodInfo {
523 unsafe {
524 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
525 ::unity::il2cpp_call!((::unity::module_base()+0x3381e50usize)as*mut u8,crate::system::reflection::methodinfo::MethodInfo;
526(MonoMethod)__receiver,(::unity::Array< ::unity::SystemType>)::core::convert::Into::into(types))
527 }
528 }
529 #[doc = "`GetGenericArguments()` overload"]
530 fn get_generic_arguments(self) -> ::unity::Array<::unity::SystemType> {
531 unsafe {
532 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
533 {
534 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
535 let __vi = *__vt.get(23usize).unwrap_or_else(|| {
536 panic!(
537 "unity: virtual slot {}
538 out of range (vtable len {}
539) on the runtime class behind {}
540 (method `{}
541`)",
542 23usize,
543 __vt.len(),
544 <MonoMethod as ::unity::ClassIdentity>::NAME,
545 "GetGenericArguments",
546 )
547 });
548 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> ::unity::Array<::unity::SystemType> =
549 ::core::mem::transmute(__vi.method_ptr);
550 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
551 __inner(__receiver, __mi)
552 }
553 }
554 }
555 #[doc = "`GetGenericMethodDefinition_impl()` overload"]
556 fn get_generic_method_definition_impl(self) -> crate::system::reflection::methodinfo::MethodInfo {
557 unsafe {
558 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
559 ::unity::il2cpp_call!((::unity::module_base()+0x3381e70usize)as*mut u8,crate::system::reflection::methodinfo::MethodInfo;
560(MonoMethod)__receiver)
561 }
562 }
563 #[doc = "`GetGenericMethodDefinition()` overload"]
564 fn get_generic_method_definition(self) -> crate::system::reflection::methodinfo::MethodInfo {
565 unsafe {
566 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
567 {
568 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
569 let __vi = *__vt.get(45usize).unwrap_or_else(|| {
570 panic!(
571 "unity: virtual slot {}
572 out of range (vtable len {}
573) on the runtime class behind {}
574 (method `{}
575`)",
576 45usize,
577 __vt.len(),
578 <MonoMethod as ::unity::ClassIdentity>::NAME,
579 "GetGenericMethodDefinition",
580 )
581 });
582 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> crate::system::reflection::methodinfo::MethodInfo =
583 ::core::mem::transmute(__vi.method_ptr);
584 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
585 __inner(__receiver, __mi)
586 }
587 }
588 }
589 #[doc = "`get_IsGenericMethodDefinition()` overload"]
590 fn get_is_generic_method_definition(self) -> bool {
591 unsafe {
592 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
593 {
594 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
595 let __vi = *__vt.get(24usize).unwrap_or_else(|| {
596 panic!(
597 "unity: virtual slot {}
598 out of range (vtable len {}
599) on the runtime class behind {}
600 (method `{}
601`)",
602 24usize,
603 __vt.len(),
604 <MonoMethod as ::unity::ClassIdentity>::NAME,
605 "get_IsGenericMethodDefinition",
606 )
607 });
608 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
609 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
610 __inner(__receiver, __mi)
611 }
612 }
613 }
614 #[doc = "`get_IsGenericMethod()` overload"]
615 fn get_is_generic_method(self) -> bool {
616 unsafe {
617 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
618 {
619 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
620 let __vi = *__vt.get(26usize).unwrap_or_else(|| {
621 panic!(
622 "unity: virtual slot {}
623 out of range (vtable len {}
624) on the runtime class behind {}
625 (method `{}
626`)",
627 26usize,
628 __vt.len(),
629 <MonoMethod as ::unity::ClassIdentity>::NAME,
630 "get_IsGenericMethod",
631 )
632 });
633 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
634 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
635 __inner(__receiver, __mi)
636 }
637 }
638 }
639 #[doc = "`get_ContainsGenericParameters()` overload"]
640 fn get_contains_generic_parameters(self) -> bool {
641 unsafe {
642 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
643 {
644 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
645 let __vi = *__vt.get(25usize).unwrap_or_else(|| {
646 panic!(
647 "unity: virtual slot {}
648 out of range (vtable len {}
649) on the runtime class behind {}
650 (method `{}
651`)",
652 25usize,
653 __vt.len(),
654 <MonoMethod as ::unity::ClassIdentity>::NAME,
655 "get_ContainsGenericParameters",
656 )
657 });
658 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
659 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
660 __inner(__receiver, __mi)
661 }
662 }
663 }
664 #[doc = "`GetCustomAttributesData()` overload"]
665 fn get_custom_attributes_data(
666 self,
667 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
668 {
669 unsafe {
670 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
671 {
672 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
673 let __vi = *__vt.get(13usize).unwrap_or_else(|| {
674 panic!(
675 "unity: virtual slot {}
676 out of range (vtable len {}
677) on the runtime class behind {}
678 (method `{}
679`)",
680 13usize,
681 __vt.len(),
682 <MonoMethod as ::unity::ClassIdentity>::NAME,
683 "GetCustomAttributesData",
684 )
685 });
686 let __inner: extern "C" fn(
687 MonoMethod,
688 ::unity::OptionalMethod,
689 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
690 crate::system::reflection::customattributedata::CustomAttributeData,
691 > = ::core::mem::transmute(__vi.method_ptr);
692 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
693 __inner(__receiver, __mi)
694 }
695 }
696 }
697 #[doc = "`get_IsSecurityCritical()` overload"]
698 fn get_is_security_critical(self) -> bool {
699 unsafe {
700 let __receiver = <MonoMethod as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
701 {
702 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
703 let __vi = *__vt.get(27usize).unwrap_or_else(|| {
704 panic!(
705 "unity: virtual slot {}
706 out of range (vtable len {}
707) on the runtime class behind {}
708 (method `{}
709`)",
710 27usize,
711 __vt.len(),
712 <MonoMethod as ::unity::ClassIdentity>::NAME,
713 "get_IsSecurityCritical",
714 )
715 });
716 let __inner: extern "C" fn(MonoMethod, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
717 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
718 __inner(__receiver, __mi)
719 }
720 }
721 }
722}
723
724#[cfg(feature = "system-reflection-monomethod")]
725impl<__T: IMonoMethod> IMonoMethodMethods for __T {}
726
727#[cfg(feature = "system-reflection-monomethod")]
728impl MonoMethod {
729 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
730 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
731 }
732
733 pub fn get_name_method_info() -> &'static ::unity::il2cpp::MethodInfo {
734 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
735 }
736
737 pub fn get_base_method_method_info() -> &'static ::unity::il2cpp::MethodInfo {
738 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
739 }
740
741 pub fn get_base_method_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
742 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
743 }
744
745 pub fn get_return_type_method_info() -> &'static ::unity::il2cpp::MethodInfo {
746 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
747 }
748
749 pub fn get_method_implementation_flags_method_info() -> &'static ::unity::il2cpp::MethodInfo {
750 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
751 }
752
753 pub fn get_parameters_method_info() -> &'static ::unity::il2cpp::MethodInfo {
754 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
755 }
756
757 pub fn get_parameters_internal_method_info() -> &'static ::unity::il2cpp::MethodInfo {
758 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
759 }
760
761 pub fn get_parameters_count_method_info() -> &'static ::unity::il2cpp::MethodInfo {
762 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
763 }
764
765 pub fn get_attributes_method_info() -> &'static ::unity::il2cpp::MethodInfo {
766 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[13]
767 }
768
769 pub fn get_calling_convention_method_info() -> &'static ::unity::il2cpp::MethodInfo {
770 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[14]
771 }
772
773 pub fn get_reflected_type_method_info() -> &'static ::unity::il2cpp::MethodInfo {
774 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[15]
775 }
776
777 pub fn get_declaring_type_method_info() -> &'static ::unity::il2cpp::MethodInfo {
778 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[16]
779 }
780
781 pub fn get_name_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
782 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[17]
783 }
784
785 pub fn is_defined_method_info() -> &'static ::unity::il2cpp::MethodInfo {
786 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[18]
787 }
788
789 pub fn get_custom_attributes_method_info() -> &'static ::unity::il2cpp::MethodInfo {
790 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[19]
791 }
792
793 pub fn get_custom_attributes_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
794 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[20]
795 }
796
797 pub fn get_p_invoke_method_info() -> &'static ::unity::il2cpp::MethodInfo {
798 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[21]
799 }
800
801 pub fn get_pseudo_custom_attributes_method_info() -> &'static ::unity::il2cpp::MethodInfo {
802 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[22]
803 }
804
805 pub fn make_generic_method_method_info() -> &'static ::unity::il2cpp::MethodInfo {
806 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[23]
807 }
808
809 pub fn make_generic_method_impl_method_info() -> &'static ::unity::il2cpp::MethodInfo {
810 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[24]
811 }
812
813 pub fn get_generic_arguments_method_info() -> &'static ::unity::il2cpp::MethodInfo {
814 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[25]
815 }
816
817 pub fn get_generic_method_definition_impl_method_info() -> &'static ::unity::il2cpp::MethodInfo {
818 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[26]
819 }
820
821 pub fn get_generic_method_definition_method_info() -> &'static ::unity::il2cpp::MethodInfo {
822 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[27]
823 }
824
825 pub fn get_is_generic_method_definition_method_info() -> &'static ::unity::il2cpp::MethodInfo {
826 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[28]
827 }
828
829 pub fn get_is_generic_method_method_info() -> &'static ::unity::il2cpp::MethodInfo {
830 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[29]
831 }
832
833 pub fn get_contains_generic_parameters_method_info() -> &'static ::unity::il2cpp::MethodInfo {
834 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[30]
835 }
836
837 pub fn get_custom_attributes_data_method_info() -> &'static ::unity::il2cpp::MethodInfo {
838 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[31]
839 }
840
841 pub fn get_core_clr_security_level_method_info() -> &'static ::unity::il2cpp::MethodInfo {
842 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[32]
843 }
844
845 pub fn get_is_security_critical_method_info() -> &'static ::unity::il2cpp::MethodInfo {
846 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[33]
847 }
848}
849
850#[cfg(feature = "system-reflection-monomethod")]
851impl MonoMethod {
852 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetBaseMethod`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
853 pub unsafe fn get_base_method_2(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::reflection::methodinfo::MethodInfo {
854 let __mi = Self::get_base_method_2_method_info();
855 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::reflection::methodinfo::MethodInfo =
856 ::core::mem::transmute(__mi.method_ptr);
857 __inner(this.into(), ::core::option::Option::None)
858 }
859
860 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_ReturnType`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
861 pub unsafe fn get_return_type(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::SystemType {
862 let __mi = Self::get_return_type_method_info();
863 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__mi.method_ptr);
864 __inner(this.into(), ::core::option::Option::None)
865 }
866
867 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetMethodImplementationFlags`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
868 pub unsafe fn get_method_implementation_flags(
869 this: impl ::core::convert::Into<::unity::IlInstance>,
870 ) -> crate::system::reflection::methodimplattributes::MethodImplAttributes {
871 let __mi = Self::get_method_implementation_flags_method_info();
872 let __inner: extern "C" fn(
873 ::unity::IlInstance,
874 ::unity::OptionalMethod,
875 ) -> crate::system::reflection::methodimplattributes::MethodImplAttributes = ::core::mem::transmute(__mi.method_ptr);
876 __inner(this.into(), ::core::option::Option::None)
877 }
878
879 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetParameters`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
880 pub unsafe fn get_parameters(
881 this: impl ::core::convert::Into<::unity::IlInstance>,
882 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> {
883 let __mi = Self::get_parameters_method_info();
884 let __inner: extern "C" fn(
885 ::unity::IlInstance,
886 ::unity::OptionalMethod,
887 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> = ::core::mem::transmute(__mi.method_ptr);
888 __inner(this.into(), ::core::option::Option::None)
889 }
890
891 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetParametersInternal`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
892 pub unsafe fn get_parameters_internal(
893 this: impl ::core::convert::Into<::unity::IlInstance>,
894 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> {
895 let __mi = Self::get_parameters_internal_method_info();
896 let __inner: extern "C" fn(
897 ::unity::IlInstance,
898 ::unity::OptionalMethod,
899 ) -> ::unity::Array<crate::system::reflection::parameterinfo::ParameterInfo> = ::core::mem::transmute(__mi.method_ptr);
900 __inner(this.into(), ::core::option::Option::None)
901 }
902
903 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetParametersCount`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
904 pub unsafe fn get_parameters_count(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
905 let __mi = Self::get_parameters_count_method_info();
906 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
907 __inner(this.into(), ::core::option::Option::None)
908 }
909
910 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_Attributes`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
911 pub unsafe fn get_attributes(
912 this: impl ::core::convert::Into<::unity::IlInstance>,
913 ) -> crate::system::reflection::methodattributes::MethodAttributes {
914 let __mi = Self::get_attributes_method_info();
915 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::reflection::methodattributes::MethodAttributes =
916 ::core::mem::transmute(__mi.method_ptr);
917 __inner(this.into(), ::core::option::Option::None)
918 }
919
920 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_CallingConvention`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
921 pub unsafe fn get_calling_convention(
922 this: impl ::core::convert::Into<::unity::IlInstance>,
923 ) -> crate::system::reflection::callingconventions::CallingConventions {
924 let __mi = Self::get_calling_convention_method_info();
925 let __inner: extern "C" fn(
926 ::unity::IlInstance,
927 ::unity::OptionalMethod,
928 ) -> crate::system::reflection::callingconventions::CallingConventions = ::core::mem::transmute(__mi.method_ptr);
929 __inner(this.into(), ::core::option::Option::None)
930 }
931
932 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_ReflectedType`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
933 pub unsafe fn get_reflected_type(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::SystemType {
934 let __mi = Self::get_reflected_type_method_info();
935 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__mi.method_ptr);
936 __inner(this.into(), ::core::option::Option::None)
937 }
938
939 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_DeclaringType`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
940 pub unsafe fn get_declaring_type(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::SystemType {
941 let __mi = Self::get_declaring_type_method_info();
942 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::SystemType = ::core::mem::transmute(__mi.method_ptr);
943 __inner(this.into(), ::core::option::Option::None)
944 }
945
946 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_Name`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
947 pub unsafe fn get_name_2(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
948 let __mi = Self::get_name_2_method_info();
949 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
950 __inner(this.into(), ::core::option::Option::None)
951 }
952
953 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `IsDefined`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
954 pub unsafe fn is_defined(this: impl ::core::convert::Into<::unity::IlInstance>, attribute_type: ::unity::SystemType, inherit: bool) -> bool {
955 let __mi = Self::is_defined_method_info();
956 let __inner: extern "C" fn(::unity::IlInstance, ::unity::SystemType, bool, ::unity::OptionalMethod) -> bool =
957 ::core::mem::transmute(__mi.method_ptr);
958 __inner(this.into(), attribute_type, inherit, ::core::option::Option::None)
959 }
960
961 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetCustomAttributes`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
962 pub unsafe fn get_custom_attributes(
963 this: impl ::core::convert::Into<::unity::IlInstance>,
964 inherit: bool,
965 ) -> ::unity::Array<crate::system::object::Object> {
966 let __mi = Self::get_custom_attributes_method_info();
967 let __inner: extern "C" fn(::unity::IlInstance, bool, ::unity::OptionalMethod) -> ::unity::Array<crate::system::object::Object> =
968 ::core::mem::transmute(__mi.method_ptr);
969 __inner(this.into(), inherit, ::core::option::Option::None)
970 }
971
972 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetCustomAttributes`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
973 pub unsafe fn get_custom_attributes_2(
974 this: impl ::core::convert::Into<::unity::IlInstance>,
975 attribute_type: ::unity::SystemType,
976 inherit: bool,
977 ) -> ::unity::Array<crate::system::object::Object> {
978 let __mi = Self::get_custom_attributes_2_method_info();
979 let __inner: extern "C" fn(
980 ::unity::IlInstance,
981 ::unity::SystemType,
982 bool,
983 ::unity::OptionalMethod,
984 ) -> ::unity::Array<crate::system::object::Object> = ::core::mem::transmute(__mi.method_ptr);
985 __inner(this.into(), attribute_type, inherit, ::core::option::Option::None)
986 }
987
988 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `MakeGenericMethod`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
989 pub unsafe fn make_generic_method(
990 this: impl ::core::convert::Into<::unity::IlInstance>,
991 method_instantiation: ::unity::Array<::unity::SystemType>,
992 ) -> crate::system::reflection::methodinfo::MethodInfo {
993 let __mi = Self::make_generic_method_method_info();
994 let __inner: extern "C" fn(
995 ::unity::IlInstance,
996 ::unity::Array<::unity::SystemType>,
997 ::unity::OptionalMethod,
998 ) -> crate::system::reflection::methodinfo::MethodInfo = ::core::mem::transmute(__mi.method_ptr);
999 __inner(this.into(), method_instantiation, ::core::option::Option::None)
1000 }
1001
1002 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetGenericArguments`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1003 pub unsafe fn get_generic_arguments(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Array<::unity::SystemType> {
1004 let __mi = Self::get_generic_arguments_method_info();
1005 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Array<::unity::SystemType> =
1006 ::core::mem::transmute(__mi.method_ptr);
1007 __inner(this.into(), ::core::option::Option::None)
1008 }
1009
1010 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetGenericMethodDefinition`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1011 pub unsafe fn get_generic_method_definition(
1012 this: impl ::core::convert::Into<::unity::IlInstance>,
1013 ) -> crate::system::reflection::methodinfo::MethodInfo {
1014 let __mi = Self::get_generic_method_definition_method_info();
1015 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::reflection::methodinfo::MethodInfo =
1016 ::core::mem::transmute(__mi.method_ptr);
1017 __inner(this.into(), ::core::option::Option::None)
1018 }
1019
1020 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_IsGenericMethodDefinition`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1021 pub unsafe fn get_is_generic_method_definition(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
1022 let __mi = Self::get_is_generic_method_definition_method_info();
1023 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
1024 __inner(this.into(), ::core::option::Option::None)
1025 }
1026
1027 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_IsGenericMethod`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1028 pub unsafe fn get_is_generic_method(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
1029 let __mi = Self::get_is_generic_method_method_info();
1030 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
1031 __inner(this.into(), ::core::option::Option::None)
1032 }
1033
1034 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_ContainsGenericParameters`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1035 pub unsafe fn get_contains_generic_parameters(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
1036 let __mi = Self::get_contains_generic_parameters_method_info();
1037 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
1038 __inner(this.into(), ::core::option::Option::None)
1039 }
1040
1041 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `GetCustomAttributesData`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1042 pub unsafe fn get_custom_attributes_data(
1043 this: impl ::core::convert::Into<::unity::IlInstance>,
1044 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
1045 {
1046 let __mi = Self::get_custom_attributes_data_method_info();
1047 let __inner: extern "C" fn(
1048 ::unity::IlInstance,
1049 ::unity::OptionalMethod,
1050 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
1051 crate::system::reflection::customattributedata::CustomAttributeData,
1052 > = ::core::mem::transmute(__mi.method_ptr);
1053 __inner(this.into(), ::core::option::Option::None)
1054 }
1055
1056 #[doc = "Direct (non-virtual) call to `MonoMethod`'s own `get_IsSecurityCritical`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
1057 pub unsafe fn get_is_security_critical(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
1058 let __mi = Self::get_is_security_critical_method_info();
1059 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
1060 __inner(this.into(), ::core::option::Option::None)
1061 }
1062}
1063
1064#[cfg(feature = "system-reflection-monomethod")]
1065impl MonoMethod {
1066 #[doc = "`.ctor()` — no args"]
1067 pub fn new() -> Self {
1068 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
1069 panic!(
1070 "{}
1071::{}
1072 failed to instantiate",
1073 ::core::stringify!(MonoMethod),
1074 ::core::stringify!(new),
1075 )
1076 });
1077 <Self as IMonoMethodMethods>::ctor(this);
1078 this
1079 }
1080}
1081
1082#[cfg(feature = "system-reflection-monomethod")]
1083#[doc(hidden)]
1084pub mod prelude {
1085 pub use super::{IMonoMethod, IMonoMethodMethods, MonoMethod};
1086 #[cfg(feature = "system-object")]
1087 pub use crate::system::object::IObjectMethods;
1088 #[cfg(feature = "system-reflection-memberinfo")]
1089 pub use crate::system::reflection::memberinfo::IMemberInfoMethods;
1090 #[cfg(feature = "system-reflection-methodbase")]
1091 pub use crate::system::reflection::methodbase::IMethodBaseMethods;
1092 #[cfg(feature = "system-reflection-methodinfo")]
1093 pub use crate::system::reflection::methodinfo::IMethodInfoMethods;
1094 #[cfg(feature = "system-reflection-runtimemethodinfo")]
1095 pub use crate::system::reflection::runtimemethodinfo::IRuntimeMethodInfoMethods;
1096 pub use crate::system::{
1097 object::IObject,
1098 reflection::{memberinfo::IMemberInfo, methodbase::IMethodBase, methodinfo::IMethodInfo, runtimemethodinfo::IRuntimeMethodInfo},
1099 };
1100}