engage/generated/moon_sharp/interpreter/diagnostics/performance_counters/
dummyperformancestopwatch.rs1#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::system::object::{IObject, Object};
9
10 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/moon_sharp/interpreter/diagnostics/performance_counters/dummyperformancestopwatch/DummyPerformanceStopwatch.md"))]
11 #[::unity::class(namespace = "MoonSharp.Interpreter.Diagnostics.PerformanceCounters", name = "DummyPerformanceStopwatch")]
12 #[parent(crate::system::object::Object)]
13 pub struct DummyPerformanceStopwatch {
14 #[static_field]
15 #[rename(name = "Instance")]
16 pub instance: crate::moon_sharp::interpreter::diagnostics::performance_counters::dummyperformancestopwatch::DummyPerformanceStopwatch,
17 #[offset(16)]
18 #[rename(name = "m_Result")]
19 pub m_result: crate::moon_sharp::interpreter::diagnostics::performanceresult::PerformanceResult,
20 }
21}
22
23#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch-types")]
24pub use __types::*;
25
26#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
27#[doc(hidden)]
28#[allow(non_snake_case, non_camel_case_types, clippy::too_many_arguments)]
29mod __DummyPerformanceStopwatch_unity_raw {
30 use super::*;
31 #[doc(hidden)]
32 #[allow(non_snake_case)]
33 pub mod __lookup_ctor {
34 use super::*;
35 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
36 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
37 ::unity::lookup::method_info_on_class_with_signature(
38 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::class(),
39 ".ctor",
40 0,
41 param_types,
42 false,
43 )
44 });
45 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
46 match &*METHOD {
47 ::core::result::Result::Ok(mi) => *mi,
48 ::core::result::Result::Err(e) => {
49 panic!(
50 "method lookup failed: {}
51::{}
52: {}
53",
54 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::NAME,
55 ".ctor",
56 e
57 )
58 },
59 }
60 }
61 }
62 #[doc(hidden)]
63 #[allow(non_snake_case)]
64 pub mod __lookup_cctor {
65 use super::*;
66 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
67 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
68 ::unity::lookup::method_info_on_class_with_signature(
69 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::class(),
70 ".cctor",
71 0,
72 param_types,
73 true,
74 )
75 });
76 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
77 match &*METHOD {
78 ::core::result::Result::Ok(mi) => *mi,
79 ::core::result::Result::Err(e) => {
80 panic!(
81 "method lookup failed: {}
82::{}
83: {}
84",
85 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::NAME,
86 ".cctor",
87 e
88 )
89 },
90 }
91 }
92 }
93}
94
95#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
96impl DummyPerformanceStopwatch {
97 #[doc = "`.cctor()` overload"]
98 pub fn cctor() -> () {
99 unsafe {
100 ::unity::il2cpp_call!(__DummyPerformanceStopwatch_unity_raw::__lookup_cctor::get_method_info().method_ptr,();
101 )
102 }
103 }
104}
105
106#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
107pub trait IDummyPerformanceStopwatchMethods: IDummyPerformanceStopwatch {
108 #[doc = "`.ctor()` overload"]
109 fn ctor(self) -> () {
110 unsafe {
111 let __receiver =
112 <DummyPerformanceStopwatch as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
113 ::unity::il2cpp_call!(__DummyPerformanceStopwatch_unity_raw::__lookup_ctor::get_method_info().method_ptr,();
114(DummyPerformanceStopwatch)__receiver)
115 }
116 }
117 #[doc = "`GetResult()` overload"]
118 fn get_result(self) -> crate::moon_sharp::interpreter::diagnostics::performanceresult::PerformanceResult {
119 unsafe {
120 let __receiver =
121 <DummyPerformanceStopwatch as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
122 {
123 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
124 let __vi = *__vt.get(5usize).unwrap_or_else(|| {
125 panic!(
126 "unity: virtual slot {}
127 out of range (vtable len {}
128) on the runtime class behind {}
129 (method `{}
130`)",
131 5usize,
132 __vt.len(),
133 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::NAME,
134 "GetResult",
135 )
136 });
137 let __inner: extern "C" fn(
138 DummyPerformanceStopwatch,
139 ::unity::OptionalMethod,
140 ) -> crate::moon_sharp::interpreter::diagnostics::performanceresult::PerformanceResult = ::core::mem::transmute(__vi.method_ptr);
141 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
142 __inner(__receiver, __mi)
143 }
144 }
145 }
146 #[doc = "`Dispose()` overload"]
147 fn dispose(self) -> () {
148 unsafe {
149 let __receiver =
150 <DummyPerformanceStopwatch as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
151 {
152 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
153 let __vi = *__vt.get(6usize).unwrap_or_else(|| {
154 panic!(
155 "unity: virtual slot {}
156 out of range (vtable len {}
157) on the runtime class behind {}
158 (method `{}
159`)",
160 6usize,
161 __vt.len(),
162 <DummyPerformanceStopwatch as ::unity::ClassIdentity>::NAME,
163 "Dispose",
164 )
165 });
166 let __inner: extern "C" fn(DummyPerformanceStopwatch, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
167 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
168 __inner(__receiver, __mi)
169 }
170 }
171 }
172}
173
174#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
175impl<__T: IDummyPerformanceStopwatch> IDummyPerformanceStopwatchMethods for __T {}
176
177#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
178impl DummyPerformanceStopwatch {
179 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
180 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
181 }
182
183 pub fn get_result_method_info() -> &'static ::unity::il2cpp::MethodInfo {
184 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
185 }
186
187 pub fn dispose_method_info() -> &'static ::unity::il2cpp::MethodInfo {
188 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
189 }
190
191 pub fn cctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
192 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
193 }
194}
195
196#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
197impl DummyPerformanceStopwatch {
198 #[doc = "Direct (non-virtual) call to `DummyPerformanceStopwatch`'s own `GetResult`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
199 pub unsafe fn get_result(
200 this: impl ::core::convert::Into<::unity::IlInstance>,
201 ) -> crate::moon_sharp::interpreter::diagnostics::performanceresult::PerformanceResult {
202 let __mi = Self::get_result_method_info();
203 let __inner: extern "C" fn(
204 ::unity::IlInstance,
205 ::unity::OptionalMethod,
206 ) -> crate::moon_sharp::interpreter::diagnostics::performanceresult::PerformanceResult = ::core::mem::transmute(__mi.method_ptr);
207 __inner(this.into(), ::core::option::Option::None)
208 }
209
210 #[doc = "Direct (non-virtual) call to `DummyPerformanceStopwatch`'s own `Dispose`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
211 pub unsafe fn dispose(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
212 let __mi = Self::dispose_method_info();
213 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
214 __inner(this.into(), ::core::option::Option::None)
215 }
216}
217
218#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
219impl DummyPerformanceStopwatch {
220 #[doc = "`.ctor()` — no args"]
221 pub fn new() -> Self {
222 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
223 panic!(
224 "{}
225::{}
226 failed to instantiate",
227 ::core::stringify!(DummyPerformanceStopwatch),
228 ::core::stringify!(new),
229 )
230 });
231 <Self as IDummyPerformanceStopwatchMethods>::ctor(this);
232 this
233 }
234}
235
236#[cfg(feature = "moon_sharp-interpreter-diagnostics-performance_counters-dummyperformancestopwatch")]
237#[doc(hidden)]
238pub mod prelude {
239 pub use super::{DummyPerformanceStopwatch, IDummyPerformanceStopwatch, IDummyPerformanceStopwatchMethods};
240 pub use crate::system::object::IObject;
241 #[cfg(feature = "system-object")]
242 pub use crate::system::object::IObjectMethods;
243}