1#[cfg(feature = "system-reflection-customattributedata-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/system/reflection/customattributedata/CustomAttributeData.md"))]
11 #[::unity::class(namespace = "System.Reflection", name = "CustomAttributeData")]
12 #[parent(crate::system::object::Object)]
13 pub struct CustomAttributeData {
14 #[offset(16)]
15 #[rename(name = "ctorInfo")]
16 pub ctor_info: crate::system::reflection::constructorinfo::ConstructorInfo,
17 #[offset(24)]
18 #[rename(name = "ctorArgs")]
19 pub ctor_args: crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
20 crate::system::reflection::customattributetypedargument::CustomAttributeTypedArgument,
21 >,
22 #[offset(32)]
23 #[rename(name = "namedArgs")]
24 pub named_args: crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
25 crate::system::reflection::customattributenamedargument::CustomAttributeNamedArgument,
26 >,
27 #[offset(40)]
28 #[rename(name = "lazyData")]
29 pub lazy_data: crate::system::reflection::customattributedata::CustomAttributeData_LazyCAttrData,
30 }
31
32 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/reflection/customattributedata/CustomAttributeData_LazyCAttrData.md"))]
33 #[::unity::class(namespace = "System.Reflection", name = "CustomAttributeData.LazyCAttrData")]
34 #[parent(crate::system::object::Object)]
35 pub struct CustomAttributeData_LazyCAttrData {
36 #[offset(16)]
37 #[rename(name = "assembly")]
38 pub assembly: crate::system::reflection::assembly::Assembly,
39 #[offset(24)]
40 #[rename(name = "data")]
41 pub data: ::unity::IntPtr,
42 #[offset(32)]
43 #[rename(name = "data_length")]
44 pub data_length: u32,
45 }
46}
47
48#[cfg(feature = "system-reflection-customattributedata-types")]
49pub use __types::*;
50
51#[cfg(feature = "system-reflection-customattributedata")]
52impl CustomAttributeData {
53 #[doc = "`ResolveArgumentsInternal(crate::system::reflection::constructorinfo::ConstructorInfo, crate::system::reflection::assembly::Assembly, ::unity::IntPtr, u32, *mut::unity::Array<crate::system::object::Object>, *mut::unity::Array<crate::system::object::Object>)` overload"]
54 pub fn resolve_arguments_internal(
55 ctor: impl ::core::convert::Into<crate::system::reflection::constructorinfo::ConstructorInfo>,
56 assembly: impl ::core::convert::Into<crate::system::reflection::assembly::Assembly>,
57 data: impl ::core::convert::Into<::unity::IntPtr>,
58 data_length: impl ::core::convert::Into<u32>,
59 ) -> (
60 ::unity::Array<crate::system::object::Object>,
61 ::unity::Array<crate::system::object::Object>,
62 ) {
63 unsafe {
64 let mut __out_0 = ::core::mem::MaybeUninit::<::unity::Array<crate::system::object::Object>>::uninit();
65 let mut __out_1 = ::core::mem::MaybeUninit::<::unity::Array<crate::system::object::Object>>::uninit();
66 ::unity::il2cpp_call!((::unity::module_base()+0x3714b30usize)as*mut u8,();
67(crate::system::reflection::constructorinfo::ConstructorInfo)::core::convert::Into::into(ctor),(crate::system::reflection::assembly::Assembly)::core::convert::Into::into(assembly),(::unity::IntPtr)::core::convert::Into::into(data),(u32)::core::convert::Into::into(data_length),(*mut::unity::Array<crate::system::object::Object>)__out_0.as_mut_ptr(),(*mut::unity::Array<crate::system::object::Object>)__out_1.as_mut_ptr());
68 (__out_0.assume_init(), __out_1.assume_init())
69 }
70 }
71
72 #[doc = "`GetCustomAttributes(crate::system::reflection::assembly::Assembly)` overload"]
73 pub fn get_custom_attributes(
74 target: impl ::core::convert::Into<crate::system::reflection::assembly::Assembly>,
75 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
76 {
77 unsafe {
78 ::unity::il2cpp_call!((::unity::module_base()+0x3714d40usize)as*mut u8,crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData> ;
79(crate::system::reflection::assembly::Assembly)::core::convert::Into::into(target))
80 }
81 }
82
83 #[doc = "`GetCustomAttributes(crate::system::reflection::memberinfo::MemberInfo)` overload"]
84 pub fn get_custom_attributes_2(
85 target: impl ::core::convert::Into<crate::system::reflection::memberinfo::MemberInfo>,
86 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
87 {
88 unsafe {
89 ::unity::il2cpp_call!((::unity::module_base()+0x3714db0usize)as*mut u8,crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData> ;
90(crate::system::reflection::memberinfo::MemberInfo)::core::convert::Into::into(target))
91 }
92 }
93
94 #[doc = "`GetCustomAttributesInternal(crate::system::runtimetype::RuntimeType)` overload"]
95 pub fn get_custom_attributes_internal(
96 target: impl ::core::convert::Into<crate::system::runtimetype::RuntimeType>,
97 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
98 {
99 unsafe {
100 ::unity::il2cpp_call!((::unity::module_base()+0x3714e20usize)as*mut u8,crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData> ;
101(crate::system::runtimetype::RuntimeType)::core::convert::Into::into(target))
102 }
103 }
104
105 #[doc = "`GetCustomAttributes(crate::system::reflection::module::Module)` overload"]
106 pub fn get_custom_attributes_3(
107 target: impl ::core::convert::Into<crate::system::reflection::module::Module>,
108 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
109 {
110 unsafe {
111 ::unity::il2cpp_call!((::unity::module_base()+0x3714e90usize)as*mut u8,crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData> ;
112(crate::system::reflection::module::Module)::core::convert::Into::into(target))
113 }
114 }
115
116 #[doc = "`GetCustomAttributes(crate::system::reflection::parameterinfo::ParameterInfo)` overload"]
117 pub fn get_custom_attributes_4(
118 target: impl ::core::convert::Into<crate::system::reflection::parameterinfo::ParameterInfo>,
119 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData>
120 {
121 unsafe {
122 ::unity::il2cpp_call!((::unity::module_base()+0x3714f00usize)as*mut u8,crate::system::collections::generic::ilist_1_interface::IList_1_Interface<crate::system::reflection::customattributedata::CustomAttributeData> ;
123(crate::system::reflection::parameterinfo::ParameterInfo)::core::convert::Into::into(target))
124 }
125 }
126
127 pub fn unbox_values<M0: ::unity::IlType + ::core::marker::Copy + ::unity::ClassIdentity>(
128 values: impl ::core::convert::Into<::unity::Array<crate::system::object::Object>>,
129 ) -> ::unity::Array<M0> {
130 static OPEN: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
131 ::unity::lookup::method_info_on_class(<CustomAttributeData as ::unity::ClassIdentity>::class(), "UnboxValues", 1)
132 });
133 #[allow(clippy::type_complexity)]
134 static CACHE: ::std::sync::OnceLock<::std::sync::Mutex<::std::collections::HashMap<usize, &'static ::unity::il2cpp::MethodInfo>>> =
135 ::std::sync::OnceLock::new();
136 let _ = true;
137 let __open: &'static ::unity::il2cpp::MethodInfo = match &*OPEN {
138 ::core::result::Result::Ok(mi) => *mi,
139 ::core::result::Result::Err(e) => {
140 panic!(
141 "method lookup failed: {}
142::{}
143: {}
144",
145 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
146 "UnboxValues",
147 e
148 )
149 },
150 };
151 let __cache = CACHE.get_or_init(|| ::std::sync::Mutex::new(::std::collections::HashMap::new()));
152 let __key: usize = <M0 as ::unity::IlType>::il_type() as *const _ as usize;
153 let __inflated: &'static ::unity::il2cpp::MethodInfo = {
154 let mut __guard = __cache.lock().unwrap();
155 *__guard
156 .entry(__key)
157 .or_insert_with(|| ::unity::il2cpp::generic::create_generic_method_info(__open, &[<M0 as ::unity::IlType>::il_type()]))
158 };
159 unsafe {
160 let __f: extern "C" fn(::unity::Array<crate::system::object::Object>, ::unity::OptionalMethod) -> ::unity::Array<M0> =
161 ::core::mem::transmute(__inflated.method_ptr);
162 let __mi_opaque: &'static () = &*(__inflated as *const _ as *const ());
163 __f(::core::convert::Into::into(values), ::core::option::Option::Some(__mi_opaque))
164 }
165 }
166}
167
168#[cfg(feature = "system-reflection-customattributedata")]
169pub trait ICustomAttributeDataMethods: ICustomAttributeData {
170 #[doc = "`.ctor()` overload"]
171 fn ctor(self) -> () {
172 unsafe {
173 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
174 ::unity::il2cpp_call!((::unity::module_base()+0x3714a50usize)as*mut u8,();
175(CustomAttributeData)__receiver)
176 }
177 }
178 #[doc = "`.ctor(crate::system::reflection::constructorinfo::ConstructorInfo, crate::system::reflection::assembly::Assembly, ::unity::IntPtr, u32)` overload"]
179 fn ctor_2(
180 self,
181 ctor_info: impl ::core::convert::Into<crate::system::reflection::constructorinfo::ConstructorInfo>,
182 assembly: impl ::core::convert::Into<crate::system::reflection::assembly::Assembly>,
183 data: impl ::core::convert::Into<::unity::IntPtr>,
184 data_length: impl ::core::convert::Into<u32>,
185 ) -> () {
186 unsafe {
187 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
188 ::unity::il2cpp_call!((::unity::module_base()+0x3714a60usize)as*mut u8,();
189(CustomAttributeData)__receiver,(crate::system::reflection::constructorinfo::ConstructorInfo)::core::convert::Into::into(ctor_info),(crate::system::reflection::assembly::Assembly)::core::convert::Into::into(assembly),(::unity::IntPtr)::core::convert::Into::into(data),(u32)::core::convert::Into::into(data_length))
190 }
191 }
192 #[doc = "`ResolveArguments()` overload"]
193 fn resolve_arguments(self) -> () {
194 unsafe {
195 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
196 ::unity::il2cpp_call!((::unity::module_base()+0x3714b40usize)as*mut u8,();
197(CustomAttributeData)__receiver)
198 }
199 }
200 #[doc = "`get_Constructor()` overload"]
201 fn get_constructor(self) -> crate::system::reflection::constructorinfo::ConstructorInfo {
202 unsafe {
203 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
204 {
205 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
206 let __vi = *__vt.get(4usize).unwrap_or_else(|| {
207 panic!(
208 "unity: virtual slot {}
209 out of range (vtable len {}
210) on the runtime class behind {}
211 (method `{}
212`)",
213 4usize,
214 __vt.len(),
215 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
216 "get_Constructor",
217 )
218 });
219 let __inner: extern "C" fn(
220 CustomAttributeData,
221 ::unity::OptionalMethod,
222 ) -> crate::system::reflection::constructorinfo::ConstructorInfo = ::core::mem::transmute(__vi.method_ptr);
223 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
224 __inner(__receiver, __mi)
225 }
226 }
227 }
228 #[doc = "`get_ConstructorArguments()` overload"]
229 fn get_constructor_arguments(
230 self,
231 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
232 crate::system::reflection::customattributetypedargument::CustomAttributeTypedArgument,
233 > {
234 unsafe {
235 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
236 {
237 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
238 let __vi = *__vt.get(5usize).unwrap_or_else(|| {
239 panic!(
240 "unity: virtual slot {}
241 out of range (vtable len {}
242) on the runtime class behind {}
243 (method `{}
244`)",
245 5usize,
246 __vt.len(),
247 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
248 "get_ConstructorArguments",
249 )
250 });
251 let __inner: extern "C" fn(
252 CustomAttributeData,
253 ::unity::OptionalMethod,
254 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
255 crate::system::reflection::customattributetypedargument::CustomAttributeTypedArgument,
256 > = ::core::mem::transmute(__vi.method_ptr);
257 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
258 __inner(__receiver, __mi)
259 }
260 }
261 }
262 #[doc = "`get_NamedArguments()` overload"]
263 fn get_named_arguments(
264 self,
265 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
266 crate::system::reflection::customattributenamedargument::CustomAttributeNamedArgument,
267 > {
268 unsafe {
269 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
270 {
271 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
272 let __vi = *__vt.get(6usize).unwrap_or_else(|| {
273 panic!(
274 "unity: virtual slot {}
275 out of range (vtable len {}
276) on the runtime class behind {}
277 (method `{}
278`)",
279 6usize,
280 __vt.len(),
281 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
282 "get_NamedArguments",
283 )
284 });
285 let __inner: extern "C" fn(
286 CustomAttributeData,
287 ::unity::OptionalMethod,
288 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
289 crate::system::reflection::customattributenamedargument::CustomAttributeNamedArgument,
290 > = ::core::mem::transmute(__vi.method_ptr);
291 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
292 __inner(__receiver, __mi)
293 }
294 }
295 }
296 #[doc = "`get_AttributeType()` overload"]
297 fn get_attribute_type(self) -> ::unity::SystemType {
298 unsafe {
299 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
300 ::unity::il2cpp_call!((::unity::module_base()+0x3714f70usize)as*mut u8, ::unity::SystemType;
301(CustomAttributeData)__receiver)
302 }
303 }
304 #[doc = "`ToString()` overload"]
305 fn to_string(self) -> ::unity::Il2CppString {
306 unsafe {
307 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
308 {
309 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
310 let __vi = *__vt.get(3usize).unwrap_or_else(|| {
311 panic!(
312 "unity: virtual slot {}
313 out of range (vtable len {}
314) on the runtime class behind {}
315 (method `{}
316`)",
317 3usize,
318 __vt.len(),
319 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
320 "ToString",
321 )
322 });
323 let __inner: extern "C" fn(CustomAttributeData, ::unity::OptionalMethod) -> ::unity::Il2CppString =
324 ::core::mem::transmute(__vi.method_ptr);
325 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
326 __inner(__receiver, __mi)
327 }
328 }
329 }
330 #[doc = "`Equals(crate::system::object::Object)` overload"]
331 fn equals(self, obj: impl ::core::convert::Into<crate::system::object::Object>) -> bool {
332 unsafe {
333 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
334 {
335 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
336 let __vi = *__vt.get(0usize).unwrap_or_else(|| {
337 panic!(
338 "unity: virtual slot {}
339 out of range (vtable len {}
340) on the runtime class behind {}
341 (method `{}
342`)",
343 0usize,
344 __vt.len(),
345 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
346 "Equals",
347 )
348 });
349 let __inner: extern "C" fn(CustomAttributeData, crate::system::object::Object, ::unity::OptionalMethod) -> bool =
350 ::core::mem::transmute(__vi.method_ptr);
351 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
352 __inner(__receiver, ::core::convert::Into::into(obj), __mi)
353 }
354 }
355 }
356 #[doc = "`GetHashCode()` overload"]
357 fn get_hash_code(self) -> i32 {
358 unsafe {
359 let __receiver = <CustomAttributeData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
360 {
361 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
362 let __vi = *__vt.get(2usize).unwrap_or_else(|| {
363 panic!(
364 "unity: virtual slot {}
365 out of range (vtable len {}
366) on the runtime class behind {}
367 (method `{}
368`)",
369 2usize,
370 __vt.len(),
371 <CustomAttributeData as ::unity::ClassIdentity>::NAME,
372 "GetHashCode",
373 )
374 });
375 let __inner: extern "C" fn(CustomAttributeData, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__vi.method_ptr);
376 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
377 __inner(__receiver, __mi)
378 }
379 }
380 }
381}
382
383#[cfg(feature = "system-reflection-customattributedata")]
384impl<__T: ICustomAttributeData> ICustomAttributeDataMethods for __T {}
385
386#[cfg(feature = "system-reflection-customattributedata")]
387impl CustomAttributeData {
388 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
389 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
390 }
391
392 pub fn ctor_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
393 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
394 }
395
396 pub fn resolve_arguments_internal_method_info() -> &'static ::unity::il2cpp::MethodInfo {
397 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
398 }
399
400 pub fn resolve_arguments_method_info() -> &'static ::unity::il2cpp::MethodInfo {
401 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
402 }
403
404 pub fn get_constructor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
405 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
406 }
407
408 pub fn get_constructor_arguments_method_info() -> &'static ::unity::il2cpp::MethodInfo {
409 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
410 }
411
412 pub fn get_named_arguments_method_info() -> &'static ::unity::il2cpp::MethodInfo {
413 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
414 }
415
416 pub fn get_custom_attributes_method_info() -> &'static ::unity::il2cpp::MethodInfo {
417 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
418 }
419
420 pub fn get_custom_attributes_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
421 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
422 }
423
424 pub fn get_custom_attributes_internal_method_info() -> &'static ::unity::il2cpp::MethodInfo {
425 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
426 }
427
428 pub fn get_custom_attributes_3_method_info() -> &'static ::unity::il2cpp::MethodInfo {
429 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
430 }
431
432 pub fn get_custom_attributes_4_method_info() -> &'static ::unity::il2cpp::MethodInfo {
433 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
434 }
435
436 pub fn get_attribute_type_method_info() -> &'static ::unity::il2cpp::MethodInfo {
437 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[12]
438 }
439
440 pub fn to_string_method_info() -> &'static ::unity::il2cpp::MethodInfo {
441 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[13]
442 }
443
444 pub fn equals_method_info() -> &'static ::unity::il2cpp::MethodInfo {
445 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[15]
446 }
447
448 pub fn get_hash_code_method_info() -> &'static ::unity::il2cpp::MethodInfo {
449 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[16]
450 }
451}
452
453#[cfg(feature = "system-reflection-customattributedata")]
454impl CustomAttributeData {
455 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `get_Constructor`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
456 pub unsafe fn get_constructor(
457 this: impl ::core::convert::Into<::unity::IlInstance>,
458 ) -> crate::system::reflection::constructorinfo::ConstructorInfo {
459 let __mi = Self::get_constructor_method_info();
460 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::reflection::constructorinfo::ConstructorInfo =
461 ::core::mem::transmute(__mi.method_ptr);
462 __inner(this.into(), ::core::option::Option::None)
463 }
464
465 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `get_ConstructorArguments`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
466 pub unsafe fn get_constructor_arguments(
467 this: impl ::core::convert::Into<::unity::IlInstance>,
468 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
469 crate::system::reflection::customattributetypedargument::CustomAttributeTypedArgument,
470 > {
471 let __mi = Self::get_constructor_arguments_method_info();
472 let __inner: extern "C" fn(
473 ::unity::IlInstance,
474 ::unity::OptionalMethod,
475 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
476 crate::system::reflection::customattributetypedargument::CustomAttributeTypedArgument,
477 > = ::core::mem::transmute(__mi.method_ptr);
478 __inner(this.into(), ::core::option::Option::None)
479 }
480
481 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `get_NamedArguments`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
482 pub unsafe fn get_named_arguments(
483 this: impl ::core::convert::Into<::unity::IlInstance>,
484 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
485 crate::system::reflection::customattributenamedargument::CustomAttributeNamedArgument,
486 > {
487 let __mi = Self::get_named_arguments_method_info();
488 let __inner: extern "C" fn(
489 ::unity::IlInstance,
490 ::unity::OptionalMethod,
491 ) -> crate::system::collections::generic::ilist_1_interface::IList_1_Interface<
492 crate::system::reflection::customattributenamedargument::CustomAttributeNamedArgument,
493 > = ::core::mem::transmute(__mi.method_ptr);
494 __inner(this.into(), ::core::option::Option::None)
495 }
496
497 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `ToString`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
498 pub unsafe fn to_string(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
499 let __mi = Self::to_string_method_info();
500 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
501 __inner(this.into(), ::core::option::Option::None)
502 }
503
504 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `Equals`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
505 pub unsafe fn equals(this: impl ::core::convert::Into<::unity::IlInstance>, obj: crate::system::object::Object) -> bool {
506 let __mi = Self::equals_method_info();
507 let __inner: extern "C" fn(::unity::IlInstance, crate::system::object::Object, ::unity::OptionalMethod) -> bool =
508 ::core::mem::transmute(__mi.method_ptr);
509 __inner(this.into(), obj, ::core::option::Option::None)
510 }
511
512 #[doc = "Direct (non-virtual) call to `CustomAttributeData`'s own `GetHashCode`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
513 pub unsafe fn get_hash_code(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
514 let __mi = Self::get_hash_code_method_info();
515 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
516 __inner(this.into(), ::core::option::Option::None)
517 }
518}
519
520#[cfg(feature = "system-reflection-customattributedata")]
521impl CustomAttributeData {
522 #[doc = "`.ctor()` — no args"]
523 pub fn new() -> Self {
524 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
525 panic!(
526 "{}
527::{}
528 failed to instantiate",
529 ::core::stringify!(CustomAttributeData),
530 ::core::stringify!(new),
531 )
532 });
533 <Self as ICustomAttributeDataMethods>::ctor(this);
534 this
535 }
536
537 #[doc = "`.ctor(crate::system::reflection::constructorinfo::ConstructorInfo, crate::system::reflection::assembly::Assembly, ::unity::IntPtr, u32)` — overload selector"]
538 pub fn new_2(
539 ctor_info: crate::system::reflection::constructorinfo::ConstructorInfo,
540 assembly: crate::system::reflection::assembly::Assembly,
541 data: ::unity::IntPtr,
542 data_length: u32,
543 ) -> Self {
544 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
545 panic!(
546 "{}
547::{}
548 failed to instantiate",
549 ::core::stringify!(CustomAttributeData),
550 ::core::stringify!(new_2),
551 )
552 });
553 <Self as ICustomAttributeDataMethods>::ctor_2(this, ctor_info, assembly, data, data_length);
554 this
555 }
556}
557
558#[cfg(feature = "system-reflection-customattributedata")]
559pub trait ICustomAttributeData_LazyCAttrDataMethods: ICustomAttributeData_LazyCAttrData {
560 #[doc = "`.ctor()` overload"]
561 fn ctor(self) -> () {
562 unsafe {
563 let __receiver =
564 <CustomAttributeData_LazyCAttrData as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
565 ::unity::il2cpp_call!((::unity::module_base()+0x34d3570usize)as*mut u8,();
566(CustomAttributeData_LazyCAttrData)__receiver)
567 }
568 }
569}
570
571#[cfg(feature = "system-reflection-customattributedata")]
572impl<__T: ICustomAttributeData_LazyCAttrData> ICustomAttributeData_LazyCAttrDataMethods for __T {}
573
574#[cfg(feature = "system-reflection-customattributedata")]
575impl CustomAttributeData_LazyCAttrData {
576 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
577 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
578 }
579}
580
581#[cfg(feature = "system-reflection-customattributedata")]
582impl CustomAttributeData_LazyCAttrData {
583 #[doc = "`.ctor()` — no args"]
584 pub fn new() -> Self {
585 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
586 panic!(
587 "{}
588::{}
589 failed to instantiate",
590 ::core::stringify!(CustomAttributeData_LazyCAttrData),
591 ::core::stringify!(new),
592 )
593 });
594 <Self as ICustomAttributeData_LazyCAttrDataMethods>::ctor(this);
595 this
596 }
597}
598
599#[cfg(feature = "system-reflection-customattributedata")]
600#[doc(hidden)]
601pub mod prelude {
602 pub use super::{
603 CustomAttributeData, CustomAttributeData_LazyCAttrData, ICustomAttributeData, ICustomAttributeDataMethods,
604 ICustomAttributeData_LazyCAttrData, ICustomAttributeData_LazyCAttrDataMethods,
605 };
606 pub use crate::system::object::IObject;
607 #[cfg(feature = "system-object")]
608 pub use crate::system::object::IObjectMethods;
609}