Skip to main content

engage/generated/system/collections/
stack.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "system-collections-stack-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/collections/stack/Stack_StackDebugView.md"))]
11    #[::unity::class(namespace = "System.Collections", name = "Stack.StackDebugView")]
12    #[parent(crate::system::object::Object)]
13    pub struct Stack_StackDebugView {}
14
15    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/collections/stack/Stack_StackEnumerator.md"))]
16    #[::unity::class(namespace = "System.Collections", name = "Stack.StackEnumerator")]
17    #[parent(crate::system::object::Object)]
18    pub struct Stack_StackEnumerator {
19        #[offset(16)]
20        #[rename(name = "_stack")]
21        pub stack: crate::system::collections::stack::Stack,
22        #[offset(24)]
23        #[rename(name = "_index")]
24        pub index: i32,
25        #[offset(28)]
26        #[rename(name = "_version")]
27        pub version: i32,
28        #[offset(32)]
29        #[rename(name = "currentElement")]
30        pub current_element: ::unity::IlInstance,
31    }
32
33    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/collections/stack/Stack.md"))]
34    #[::unity::class(namespace = "System.Collections", name = "Stack")]
35    #[parent(crate::system::object::Object)]
36    pub struct Stack {
37        #[offset(16)]
38        #[rename(name = "_array")]
39        pub array: ::unity::Array<crate::system::object::Object>,
40        #[offset(24)]
41        #[rename(name = "_size")]
42        pub size: i32,
43        #[offset(28)]
44        #[rename(name = "_version")]
45        pub version: i32,
46        #[offset(32)]
47        #[rename(name = "_syncRoot")]
48        pub sync_root: ::unity::IlInstance,
49    }
50}
51
52#[cfg(feature = "system-collections-stack-types")]
53pub use __types::*;
54
55#[cfg(feature = "system-collections-stack")]
56pub trait IStack_StackEnumeratorMethods: IStack_StackEnumerator {
57    #[doc = "`.ctor(crate::system::collections::stack::Stack)` overload"]
58    fn ctor(self, stack: impl ::core::convert::Into<crate::system::collections::stack::Stack>) -> () {
59        unsafe {
60            let __receiver = <Stack_StackEnumerator as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
61            ::unity::il2cpp_call!((::unity::module_base()+0x3c57c40usize)as*mut u8,();
62(Stack_StackEnumerator)__receiver,(crate::system::collections::stack::Stack)::core::convert::Into::into(stack))
63        }
64    }
65    #[doc = "`Clone()` overload"]
66    fn clone(self) -> crate::system::object::Object {
67        unsafe {
68            let __receiver = <Stack_StackEnumerator as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
69            {
70                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
71                let __vi = *__vt.get(7usize).unwrap_or_else(|| {
72                    panic!(
73                        "unity: virtual slot {}
74 out of range (vtable len {}
75) on the runtime class behind {}
76 (method `{}
77`)",
78                        7usize,
79                        __vt.len(),
80                        <Stack_StackEnumerator as ::unity::ClassIdentity>::NAME,
81                        "Clone",
82                    )
83                });
84                let __inner: extern "C" fn(Stack_StackEnumerator, ::unity::OptionalMethod) -> crate::system::object::Object =
85                    ::core::mem::transmute(__vi.method_ptr);
86                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
87                __inner(__receiver, __mi)
88            }
89        }
90    }
91    #[doc = "`MoveNext()` overload"]
92    fn move_next(self) -> bool {
93        unsafe {
94            let __receiver = <Stack_StackEnumerator as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
95            {
96                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
97                let __vi = *__vt.get(8usize).unwrap_or_else(|| {
98                    panic!(
99                        "unity: virtual slot {}
100 out of range (vtable len {}
101) on the runtime class behind {}
102 (method `{}
103`)",
104                        8usize,
105                        __vt.len(),
106                        <Stack_StackEnumerator as ::unity::ClassIdentity>::NAME,
107                        "MoveNext",
108                    )
109                });
110                let __inner: extern "C" fn(Stack_StackEnumerator, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
111                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
112                __inner(__receiver, __mi)
113            }
114        }
115    }
116    #[doc = "`get_Current()` overload"]
117    fn get_current(self) -> crate::system::object::Object {
118        unsafe {
119            let __receiver = <Stack_StackEnumerator as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
120            {
121                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
122                let __vi = *__vt.get(9usize).unwrap_or_else(|| {
123                    panic!(
124                        "unity: virtual slot {}
125 out of range (vtable len {}
126) on the runtime class behind {}
127 (method `{}
128`)",
129                        9usize,
130                        __vt.len(),
131                        <Stack_StackEnumerator as ::unity::ClassIdentity>::NAME,
132                        "get_Current",
133                    )
134                });
135                let __inner: extern "C" fn(Stack_StackEnumerator, ::unity::OptionalMethod) -> crate::system::object::Object =
136                    ::core::mem::transmute(__vi.method_ptr);
137                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
138                __inner(__receiver, __mi)
139            }
140        }
141    }
142    #[doc = "`Reset()` overload"]
143    fn reset(self) -> () {
144        unsafe {
145            let __receiver = <Stack_StackEnumerator as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
146            {
147                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
148                let __vi = *__vt.get(10usize).unwrap_or_else(|| {
149                    panic!(
150                        "unity: virtual slot {}
151 out of range (vtable len {}
152) on the runtime class behind {}
153 (method `{}
154`)",
155                        10usize,
156                        __vt.len(),
157                        <Stack_StackEnumerator as ::unity::ClassIdentity>::NAME,
158                        "Reset",
159                    )
160                });
161                let __inner: extern "C" fn(Stack_StackEnumerator, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
162                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
163                __inner(__receiver, __mi)
164            }
165        }
166    }
167}
168
169#[cfg(feature = "system-collections-stack")]
170impl<__T: IStack_StackEnumerator> IStack_StackEnumeratorMethods for __T {}
171
172#[cfg(feature = "system-collections-stack")]
173impl Stack_StackEnumerator {
174    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
175        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
176    }
177
178    pub fn clone_method_info() -> &'static ::unity::il2cpp::MethodInfo {
179        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
180    }
181
182    pub fn move_next_method_info() -> &'static ::unity::il2cpp::MethodInfo {
183        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
184    }
185
186    pub fn get_current_method_info() -> &'static ::unity::il2cpp::MethodInfo {
187        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
188    }
189
190    pub fn reset_method_info() -> &'static ::unity::il2cpp::MethodInfo {
191        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
192    }
193}
194
195#[cfg(feature = "system-collections-stack")]
196impl Stack_StackEnumerator {
197    #[doc = "Direct (non-virtual) call to `Stack_StackEnumerator`'s own `Clone`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
198    pub unsafe fn clone(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
199        let __mi = Self::clone_method_info();
200        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
201            ::core::mem::transmute(__mi.method_ptr);
202        __inner(this.into(), ::core::option::Option::None)
203    }
204
205    #[doc = "Direct (non-virtual) call to `Stack_StackEnumerator`'s own `MoveNext`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
206    pub unsafe fn move_next(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
207        let __mi = Self::move_next_method_info();
208        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
209        __inner(this.into(), ::core::option::Option::None)
210    }
211
212    #[doc = "Direct (non-virtual) call to `Stack_StackEnumerator`'s own `get_Current`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
213    pub unsafe fn get_current(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
214        let __mi = Self::get_current_method_info();
215        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
216            ::core::mem::transmute(__mi.method_ptr);
217        __inner(this.into(), ::core::option::Option::None)
218    }
219
220    #[doc = "Direct (non-virtual) call to `Stack_StackEnumerator`'s own `Reset`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
221    pub unsafe fn reset(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
222        let __mi = Self::reset_method_info();
223        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
224        __inner(this.into(), ::core::option::Option::None)
225    }
226}
227
228#[cfg(feature = "system-collections-stack")]
229impl Stack_StackEnumerator {
230    #[doc = "`.ctor(crate::system::collections::stack::Stack)` — overload selector"]
231    pub fn new(stack: crate::system::collections::stack::Stack) -> Self {
232        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
233            panic!(
234                "{}
235::{}
236 failed to instantiate",
237                ::core::stringify!(Stack_StackEnumerator),
238                ::core::stringify!(new),
239            )
240        });
241        <Self as IStack_StackEnumeratorMethods>::ctor(this, stack);
242        this
243    }
244}
245
246#[cfg(feature = "system-collections-stack")]
247pub trait IStackMethods: IStack {
248    #[doc = "`.ctor()` overload"]
249    fn ctor(self) -> () {
250        unsafe {
251            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
252            ::unity::il2cpp_call!((::unity::module_base()+0x376f0a0usize)as*mut u8,();
253(Stack)__receiver)
254        }
255    }
256    #[doc = "`.ctor(i32)` overload"]
257    fn ctor_2(self, initial_capacity: impl ::core::convert::Into<i32>) -> () {
258        unsafe {
259            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
260            ::unity::il2cpp_call!((::unity::module_base()+0x3777890usize)as*mut u8,();
261(Stack)__receiver,(i32)::core::convert::Into::into(initial_capacity))
262        }
263    }
264    #[doc = "`get_Count()` overload"]
265    fn get_count(self) -> i32 {
266        unsafe {
267            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
268            {
269                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
270                let __vi = *__vt.get(10usize).unwrap_or_else(|| {
271                    panic!(
272                        "unity: virtual slot {}
273 out of range (vtable len {}
274) on the runtime class behind {}
275 (method `{}
276`)",
277                        10usize,
278                        __vt.len(),
279                        <Stack as ::unity::ClassIdentity>::NAME,
280                        "get_Count",
281                    )
282                });
283                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> i32 = ::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_IsSynchronized()` overload"]
290    fn get_is_synchronized(self) -> bool {
291        unsafe {
292            let __receiver = <Stack 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(11usize).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                        11usize,
303                        __vt.len(),
304                        <Stack as ::unity::ClassIdentity>::NAME,
305                        "get_IsSynchronized",
306                    )
307                });
308                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> bool = ::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_SyncRoot()` overload"]
315    fn get_sync_root(self) -> crate::system::object::Object {
316        unsafe {
317            let __receiver = <Stack 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(12usize).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                        12usize,
328                        __vt.len(),
329                        <Stack as ::unity::ClassIdentity>::NAME,
330                        "get_SyncRoot",
331                    )
332                });
333                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> crate::system::object::Object = ::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 = "`Clear()` overload"]
340    fn clear(self) -> () {
341        unsafe {
342            let __receiver = <Stack 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(13usize).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                        13usize,
353                        __vt.len(),
354                        <Stack as ::unity::ClassIdentity>::NAME,
355                        "Clear",
356                    )
357                });
358                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> () = ::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 = "`Clone()` overload"]
365    fn clone(self) -> crate::system::object::Object {
366        unsafe {
367            let __receiver = <Stack 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(14usize).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                        14usize,
378                        __vt.len(),
379                        <Stack as ::unity::ClassIdentity>::NAME,
380                        "Clone",
381                    )
382                });
383                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> crate::system::object::Object = ::core::mem::transmute(__vi.method_ptr);
384                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
385                __inner(__receiver, __mi)
386            }
387        }
388    }
389    #[doc = "`CopyTo(::unity::IlInstance, i32)` overload"]
390    fn copy_to(self, array: impl ::core::convert::Into<::unity::IlInstance>, index: impl ::core::convert::Into<i32>) -> () {
391        unsafe {
392            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
393            {
394                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
395                let __vi = *__vt.get(15usize).unwrap_or_else(|| {
396                    panic!(
397                        "unity: virtual slot {}
398 out of range (vtable len {}
399) on the runtime class behind {}
400 (method `{}
401`)",
402                        15usize,
403                        __vt.len(),
404                        <Stack as ::unity::ClassIdentity>::NAME,
405                        "CopyTo",
406                    )
407                });
408                let __inner: extern "C" fn(Stack, ::unity::IlInstance, i32, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
409                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
410                __inner(__receiver, ::core::convert::Into::into(array), ::core::convert::Into::into(index), __mi)
411            }
412        }
413    }
414    #[doc = "`GetEnumerator()` overload"]
415    fn get_enumerator(self) -> crate::system::collections::ienumerator::IEnumerator {
416        unsafe {
417            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
418            {
419                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
420                let __vi = *__vt.get(16usize).unwrap_or_else(|| {
421                    panic!(
422                        "unity: virtual slot {}
423 out of range (vtable len {}
424) on the runtime class behind {}
425 (method `{}
426`)",
427                        16usize,
428                        __vt.len(),
429                        <Stack as ::unity::ClassIdentity>::NAME,
430                        "GetEnumerator",
431                    )
432                });
433                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> crate::system::collections::ienumerator::IEnumerator =
434                    ::core::mem::transmute(__vi.method_ptr);
435                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
436                __inner(__receiver, __mi)
437            }
438        }
439    }
440    #[doc = "`Peek()` overload"]
441    fn peek(self) -> crate::system::object::Object {
442        unsafe {
443            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
444            {
445                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
446                let __vi = *__vt.get(17usize).unwrap_or_else(|| {
447                    panic!(
448                        "unity: virtual slot {}
449 out of range (vtable len {}
450) on the runtime class behind {}
451 (method `{}
452`)",
453                        17usize,
454                        __vt.len(),
455                        <Stack as ::unity::ClassIdentity>::NAME,
456                        "Peek",
457                    )
458                });
459                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> crate::system::object::Object = ::core::mem::transmute(__vi.method_ptr);
460                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
461                __inner(__receiver, __mi)
462            }
463        }
464    }
465    #[doc = "`Pop()` overload"]
466    fn pop(self) -> crate::system::object::Object {
467        unsafe {
468            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
469            {
470                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
471                let __vi = *__vt.get(18usize).unwrap_or_else(|| {
472                    panic!(
473                        "unity: virtual slot {}
474 out of range (vtable len {}
475) on the runtime class behind {}
476 (method `{}
477`)",
478                        18usize,
479                        __vt.len(),
480                        <Stack as ::unity::ClassIdentity>::NAME,
481                        "Pop",
482                    )
483                });
484                let __inner: extern "C" fn(Stack, ::unity::OptionalMethod) -> crate::system::object::Object = ::core::mem::transmute(__vi.method_ptr);
485                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
486                __inner(__receiver, __mi)
487            }
488        }
489    }
490    #[doc = "`Push(crate::system::object::Object)` overload"]
491    fn push(self, obj: impl ::core::convert::Into<crate::system::object::Object>) -> () {
492        unsafe {
493            let __receiver = <Stack as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
494            {
495                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
496                let __vi = *__vt.get(19usize).unwrap_or_else(|| {
497                    panic!(
498                        "unity: virtual slot {}
499 out of range (vtable len {}
500) on the runtime class behind {}
501 (method `{}
502`)",
503                        19usize,
504                        __vt.len(),
505                        <Stack as ::unity::ClassIdentity>::NAME,
506                        "Push",
507                    )
508                });
509                let __inner: extern "C" fn(Stack, crate::system::object::Object, ::unity::OptionalMethod) -> () =
510                    ::core::mem::transmute(__vi.method_ptr);
511                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
512                __inner(__receiver, ::core::convert::Into::into(obj), __mi)
513            }
514        }
515    }
516}
517
518#[cfg(feature = "system-collections-stack")]
519impl<__T: IStack> IStackMethods for __T {}
520
521#[cfg(feature = "system-collections-stack")]
522impl Stack {
523    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
524        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
525    }
526
527    pub fn ctor_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
528        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
529    }
530
531    pub fn get_count_method_info() -> &'static ::unity::il2cpp::MethodInfo {
532        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
533    }
534
535    pub fn get_is_synchronized_method_info() -> &'static ::unity::il2cpp::MethodInfo {
536        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
537    }
538
539    pub fn get_sync_root_method_info() -> &'static ::unity::il2cpp::MethodInfo {
540        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
541    }
542
543    pub fn clear_method_info() -> &'static ::unity::il2cpp::MethodInfo {
544        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
545    }
546
547    pub fn clone_method_info() -> &'static ::unity::il2cpp::MethodInfo {
548        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
549    }
550
551    pub fn copy_to_method_info() -> &'static ::unity::il2cpp::MethodInfo {
552        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
553    }
554
555    pub fn get_enumerator_method_info() -> &'static ::unity::il2cpp::MethodInfo {
556        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
557    }
558
559    pub fn peek_method_info() -> &'static ::unity::il2cpp::MethodInfo {
560        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
561    }
562
563    pub fn pop_method_info() -> &'static ::unity::il2cpp::MethodInfo {
564        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
565    }
566
567    pub fn push_method_info() -> &'static ::unity::il2cpp::MethodInfo {
568        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
569    }
570}
571
572#[cfg(feature = "system-collections-stack")]
573impl Stack {
574    #[doc = "Direct (non-virtual) call to `Stack`'s own `get_Count`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
575    pub unsafe fn get_count(this: impl ::core::convert::Into<::unity::IlInstance>) -> i32 {
576        let __mi = Self::get_count_method_info();
577        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> i32 = ::core::mem::transmute(__mi.method_ptr);
578        __inner(this.into(), ::core::option::Option::None)
579    }
580
581    #[doc = "Direct (non-virtual) call to `Stack`'s own `get_IsSynchronized`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
582    pub unsafe fn get_is_synchronized(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
583        let __mi = Self::get_is_synchronized_method_info();
584        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
585        __inner(this.into(), ::core::option::Option::None)
586    }
587
588    #[doc = "Direct (non-virtual) call to `Stack`'s own `get_SyncRoot`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
589    pub unsafe fn get_sync_root(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
590        let __mi = Self::get_sync_root_method_info();
591        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
592            ::core::mem::transmute(__mi.method_ptr);
593        __inner(this.into(), ::core::option::Option::None)
594    }
595
596    #[doc = "Direct (non-virtual) call to `Stack`'s own `Clear`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
597    pub unsafe fn clear(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
598        let __mi = Self::clear_method_info();
599        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
600        __inner(this.into(), ::core::option::Option::None)
601    }
602
603    #[doc = "Direct (non-virtual) call to `Stack`'s own `Clone`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
604    pub unsafe fn clone(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
605        let __mi = Self::clone_method_info();
606        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
607            ::core::mem::transmute(__mi.method_ptr);
608        __inner(this.into(), ::core::option::Option::None)
609    }
610
611    #[doc = "Direct (non-virtual) call to `Stack`'s own `CopyTo`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
612    pub unsafe fn copy_to(this: impl ::core::convert::Into<::unity::IlInstance>, array: ::unity::IlInstance, index: i32) -> () {
613        let __mi = Self::copy_to_method_info();
614        let __inner: extern "C" fn(::unity::IlInstance, ::unity::IlInstance, i32, ::unity::OptionalMethod) -> () =
615            ::core::mem::transmute(__mi.method_ptr);
616        __inner(this.into(), array, index, ::core::option::Option::None)
617    }
618
619    #[doc = "Direct (non-virtual) call to `Stack`'s own `GetEnumerator`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
620    pub unsafe fn get_enumerator(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::collections::ienumerator::IEnumerator {
621        let __mi = Self::get_enumerator_method_info();
622        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::collections::ienumerator::IEnumerator =
623            ::core::mem::transmute(__mi.method_ptr);
624        __inner(this.into(), ::core::option::Option::None)
625    }
626
627    #[doc = "Direct (non-virtual) call to `Stack`'s own `Peek`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
628    pub unsafe fn peek(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
629        let __mi = Self::peek_method_info();
630        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
631            ::core::mem::transmute(__mi.method_ptr);
632        __inner(this.into(), ::core::option::Option::None)
633    }
634
635    #[doc = "Direct (non-virtual) call to `Stack`'s own `Pop`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
636    pub unsafe fn pop(this: impl ::core::convert::Into<::unity::IlInstance>) -> crate::system::object::Object {
637        let __mi = Self::pop_method_info();
638        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> crate::system::object::Object =
639            ::core::mem::transmute(__mi.method_ptr);
640        __inner(this.into(), ::core::option::Option::None)
641    }
642
643    #[doc = "Direct (non-virtual) call to `Stack`'s own `Push`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
644    pub unsafe fn push(this: impl ::core::convert::Into<::unity::IlInstance>, obj: crate::system::object::Object) -> () {
645        let __mi = Self::push_method_info();
646        let __inner: extern "C" fn(::unity::IlInstance, crate::system::object::Object, ::unity::OptionalMethod) -> () =
647            ::core::mem::transmute(__mi.method_ptr);
648        __inner(this.into(), obj, ::core::option::Option::None)
649    }
650}
651
652#[cfg(feature = "system-collections-stack")]
653impl Stack {
654    #[doc = "`.ctor()` — no args"]
655    pub fn new() -> Self {
656        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
657            panic!(
658                "{}
659::{}
660 failed to instantiate",
661                ::core::stringify!(Stack),
662                ::core::stringify!(new),
663            )
664        });
665        <Self as IStackMethods>::ctor(this);
666        this
667    }
668
669    #[doc = "`.ctor(i32)` — overload selector"]
670    pub fn new_2(initial_capacity: i32) -> Self {
671        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
672            panic!(
673                "{}
674::{}
675 failed to instantiate",
676                ::core::stringify!(Stack),
677                ::core::stringify!(new_2),
678            )
679        });
680        <Self as IStackMethods>::ctor_2(this, initial_capacity);
681        this
682    }
683}
684
685#[cfg(feature = "system-collections-stack")]
686#[doc(hidden)]
687pub mod prelude {
688    pub use super::{
689        IStack, IStackMethods, IStack_StackDebugView, IStack_StackEnumerator, IStack_StackEnumeratorMethods, Stack, Stack_StackDebugView,
690        Stack_StackEnumerator,
691    };
692    pub use crate::system::object::IObject;
693    #[cfg(feature = "system-object")]
694    pub use crate::system::object::IObjectMethods;
695}