engage/generated/unity_engine/resource_management/util/
unitywebrequestresult.rs1#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult-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/unity_engine/resource_management/util/unitywebrequestresult/UnityWebRequestResult.md"))]
11 #[::unity::class(namespace = "UnityEngine.ResourceManagement.Util", name = "UnityWebRequestResult")]
12 #[parent(crate::system::object::Object)]
13 pub struct UnityWebRequestResult {}
14}
15
16#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult-types")]
17pub use __types::*;
18
19#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
20#[doc(hidden)]
21#[allow(non_snake_case, non_camel_case_types, clippy::too_many_arguments)]
22mod __UnityWebRequestResult_unity_raw {
23 use super::*;
24 #[doc(hidden)]
25 #[allow(non_snake_case)]
26 pub mod __lookup_ctor {
27 use super::*;
28 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
29 let param_types: &[&'static ::unity::il2cpp::Il2CppType] =
30 &[<crate::unity_engine::networking::unitywebrequest::UnityWebRequest as ::unity::IlType>::il_type()];
31 ::unity::lookup::method_info_on_class_with_signature(
32 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
33 ".ctor",
34 1,
35 param_types,
36 false,
37 )
38 });
39 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
40 match &*METHOD {
41 ::core::result::Result::Ok(mi) => *mi,
42 ::core::result::Result::Err(e) => {
43 panic!(
44 "method lookup failed: {}
45::{}
46: {}
47",
48 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
49 ".ctor",
50 e
51 )
52 },
53 }
54 }
55 }
56 #[doc(hidden)]
57 #[allow(non_snake_case)]
58 pub mod __lookup_get_error {
59 use super::*;
60 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
61 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
62 ::unity::lookup::method_info_on_class_with_signature(
63 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
64 "get_Error",
65 0,
66 param_types,
67 false,
68 )
69 });
70 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
71 match &*METHOD {
72 ::core::result::Result::Ok(mi) => *mi,
73 ::core::result::Result::Err(e) => {
74 panic!(
75 "method lookup failed: {}
76::{}
77: {}
78",
79 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
80 "get_Error",
81 e
82 )
83 },
84 }
85 }
86 }
87 #[doc(hidden)]
88 #[allow(non_snake_case)]
89 pub mod __lookup_get_response_code {
90 use super::*;
91 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
92 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
93 ::unity::lookup::method_info_on_class_with_signature(
94 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
95 "get_ResponseCode",
96 0,
97 param_types,
98 false,
99 )
100 });
101 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
102 match &*METHOD {
103 ::core::result::Result::Ok(mi) => *mi,
104 ::core::result::Result::Err(e) => {
105 panic!(
106 "method lookup failed: {}
107::{}
108: {}
109",
110 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
111 "get_ResponseCode",
112 e
113 )
114 },
115 }
116 }
117 }
118 #[doc(hidden)]
119 #[allow(non_snake_case)]
120 pub mod __lookup_get_result {
121 use super::*;
122 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
123 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
124 ::unity::lookup::method_info_on_class_with_signature(
125 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
126 "get_Result",
127 0,
128 param_types,
129 false,
130 )
131 });
132 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
133 match &*METHOD {
134 ::core::result::Result::Ok(mi) => *mi,
135 ::core::result::Result::Err(e) => {
136 panic!(
137 "method lookup failed: {}
138::{}
139: {}
140",
141 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
142 "get_Result",
143 e
144 )
145 },
146 }
147 }
148 }
149 #[doc(hidden)]
150 #[allow(non_snake_case)]
151 pub mod __lookup_get_method {
152 use super::*;
153 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
154 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
155 ::unity::lookup::method_info_on_class_with_signature(
156 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
157 "get_Method",
158 0,
159 param_types,
160 false,
161 )
162 });
163 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
164 match &*METHOD {
165 ::core::result::Result::Ok(mi) => *mi,
166 ::core::result::Result::Err(e) => {
167 panic!(
168 "method lookup failed: {}
169::{}
170: {}
171",
172 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
173 "get_Method",
174 e
175 )
176 },
177 }
178 }
179 }
180 #[doc(hidden)]
181 #[allow(non_snake_case)]
182 pub mod __lookup_get_url {
183 use super::*;
184 static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
185 let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[];
186 ::unity::lookup::method_info_on_class_with_signature(
187 <UnityWebRequestResult as ::unity::ClassIdentity>::class(),
188 "get_Url",
189 0,
190 param_types,
191 false,
192 )
193 });
194 pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
195 match &*METHOD {
196 ::core::result::Result::Ok(mi) => *mi,
197 ::core::result::Result::Err(e) => {
198 panic!(
199 "method lookup failed: {}
200::{}
201: {}
202",
203 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
204 "get_Url",
205 e
206 )
207 },
208 }
209 }
210 }
211}
212
213#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
214pub trait IUnityWebRequestResultMethods: IUnityWebRequestResult {
215 #[doc = "`.ctor(crate::unity_engine::networking::unitywebrequest::UnityWebRequest)` overload"]
216 fn ctor(self, request: impl ::core::convert::Into<crate::unity_engine::networking::unitywebrequest::UnityWebRequest>) -> () {
217 unsafe {
218 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
219 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_ctor::get_method_info().method_ptr,();
220(UnityWebRequestResult)__receiver,(crate::unity_engine::networking::unitywebrequest::UnityWebRequest)::core::convert::Into::into(request))
221 }
222 }
223 #[doc = "`ToString()` overload"]
224 fn to_string(self) -> ::unity::Il2CppString {
225 unsafe {
226 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
227 {
228 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
229 let __vi = *__vt.get(3usize).unwrap_or_else(|| {
230 panic!(
231 "unity: virtual slot {}
232 out of range (vtable len {}
233) on the runtime class behind {}
234 (method `{}
235`)",
236 3usize,
237 __vt.len(),
238 <UnityWebRequestResult as ::unity::ClassIdentity>::NAME,
239 "ToString",
240 )
241 });
242 let __inner: extern "C" fn(UnityWebRequestResult, ::unity::OptionalMethod) -> ::unity::Il2CppString =
243 ::core::mem::transmute(__vi.method_ptr);
244 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
245 __inner(__receiver, __mi)
246 }
247 }
248 }
249 #[doc = "`get_Error()` overload"]
250 fn get_error(self) -> ::unity::Il2CppString {
251 unsafe {
252 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
253 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_get_error::get_method_info().method_ptr, ::unity::Il2CppString;
254(UnityWebRequestResult)__receiver)
255 }
256 }
257 #[doc = "`get_ResponseCode()` overload"]
258 fn get_response_code(self) -> i64 {
259 unsafe {
260 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
261 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_get_response_code::get_method_info().method_ptr,i64;
262(UnityWebRequestResult)__receiver)
263 }
264 }
265 #[doc = "`get_Result()` overload"]
266 fn get_result(self) -> crate::unity_engine::networking::unitywebrequest::UnityWebRequest_Result {
267 unsafe {
268 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
269 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_get_result::get_method_info().method_ptr,crate::unity_engine::networking::unitywebrequest::UnityWebRequest_Result;
270(UnityWebRequestResult)__receiver)
271 }
272 }
273 #[doc = "`get_Method()` overload"]
274 fn get_method(self) -> ::unity::Il2CppString {
275 unsafe {
276 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
277 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_get_method::get_method_info().method_ptr, ::unity::Il2CppString;
278(UnityWebRequestResult)__receiver)
279 }
280 }
281 #[doc = "`get_Url()` overload"]
282 fn get_url(self) -> ::unity::Il2CppString {
283 unsafe {
284 let __receiver = <UnityWebRequestResult as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
285 ::unity::il2cpp_call!(__UnityWebRequestResult_unity_raw::__lookup_get_url::get_method_info().method_ptr, ::unity::Il2CppString;
286(UnityWebRequestResult)__receiver)
287 }
288 }
289}
290
291#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
292impl<__T: IUnityWebRequestResult> IUnityWebRequestResultMethods for __T {}
293
294#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
295impl UnityWebRequestResult {
296 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
297 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
298 }
299
300 pub fn to_string_method_info() -> &'static ::unity::il2cpp::MethodInfo {
301 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
302 }
303
304 pub fn get_error_method_info() -> &'static ::unity::il2cpp::MethodInfo {
305 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
306 }
307
308 pub fn get_response_code_method_info() -> &'static ::unity::il2cpp::MethodInfo {
309 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
310 }
311
312 pub fn get_result_method_info() -> &'static ::unity::il2cpp::MethodInfo {
313 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
314 }
315
316 pub fn get_method_method_info() -> &'static ::unity::il2cpp::MethodInfo {
317 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
318 }
319
320 pub fn get_url_method_info() -> &'static ::unity::il2cpp::MethodInfo {
321 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
322 }
323}
324
325#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
326impl UnityWebRequestResult {
327 #[doc = "Direct (non-virtual) call to `UnityWebRequestResult`'s own `ToString`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
328 pub unsafe fn to_string(this: impl ::core::convert::Into<::unity::IlInstance>) -> ::unity::Il2CppString {
329 let __mi = Self::to_string_method_info();
330 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> ::unity::Il2CppString = ::core::mem::transmute(__mi.method_ptr);
331 __inner(this.into(), ::core::option::Option::None)
332 }
333}
334
335#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
336impl UnityWebRequestResult {
337 #[doc = "`.ctor(crate::unity_engine::networking::unitywebrequest::UnityWebRequest)` — overload selector"]
338 pub fn new(request: crate::unity_engine::networking::unitywebrequest::UnityWebRequest) -> Self {
339 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
340 panic!(
341 "{}
342::{}
343 failed to instantiate",
344 ::core::stringify!(UnityWebRequestResult),
345 ::core::stringify!(new),
346 )
347 });
348 <Self as IUnityWebRequestResultMethods>::ctor(this, request);
349 this
350 }
351}
352
353#[cfg(feature = "unity_engine-resource_management-util-unitywebrequestresult")]
354#[doc(hidden)]
355pub mod prelude {
356 pub use super::{IUnityWebRequestResult, IUnityWebRequestResultMethods, UnityWebRequestResult};
357 pub use crate::system::object::IObject;
358 #[cfg(feature = "system-object")]
359 pub use crate::system::object::IObjectMethods;
360}