Skip to main content

engage/generated/system/io/compression/
deflatestreamnative.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "system-io-compression-deflatestreamnative-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::system::{
9        delegate::{Delegate, IDelegate},
10        multicastdelegate::{IMulticastDelegate, MulticastDelegate},
11        object::{IObject, Object},
12    };
13
14    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/io/compression/deflatestreamnative/DeflateStreamNative.md"))]
15    #[::unity::class(namespace = "System.IO.Compression", name = "DeflateStreamNative")]
16    #[parent(crate::system::object::Object)]
17    pub struct DeflateStreamNative {
18        #[offset(16)]
19        #[rename(name = "feeder")]
20        pub feeder: crate::system::io::compression::deflatestreamnative::DeflateStreamNative_UnmanagedReadOrWrite,
21        #[offset(24)]
22        #[rename(name = "base_stream")]
23        pub base_stream: crate::system::io::stream::Stream,
24        #[offset(32)]
25        #[rename(name = "z_stream")]
26        pub z_stream: crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle,
27        #[offset(44)]
28        #[rename(name = "disposed")]
29        pub disposed: bool,
30        #[offset(48)]
31        #[rename(name = "io_buffer")]
32        pub io_buffer: ::unity::Array<u8>,
33    }
34
35    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/io/compression/deflatestreamnative/DeflateStreamNative_UnmanagedReadOrWrite.md"))]
36    #[::unity::class(namespace = "System.IO.Compression", name = "DeflateStreamNative.UnmanagedReadOrWrite")]
37    #[parent(crate::system::multicastdelegate::MulticastDelegate)]
38    pub struct DeflateStreamNative_UnmanagedReadOrWrite {}
39
40    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/io/compression/deflatestreamnative/DeflateStreamNative_SafeDeflateStreamHandle.md"))]
41    #[::unity::class(namespace = "System.IO.Compression", name = "DeflateStreamNative.SafeDeflateStreamHandle")]
42    pub struct DeflateStreamNative_SafeDeflateStreamHandle {}
43}
44
45#[cfg(feature = "system-io-compression-deflatestreamnative-types")]
46pub use __types::*;
47
48#[cfg(feature = "system-io-compression-deflatestreamnative")]
49impl DeflateStreamNative {
50    #[doc = "`Create(crate::system::io::stream::Stream, crate::system::io::compression::compressionmode::CompressionMode, bool)` overload"]
51    pub fn create(
52        compressed_stream: impl ::core::convert::Into<crate::system::io::stream::Stream>,
53        mode: impl ::core::convert::Into<crate::system::io::compression::compressionmode::CompressionMode>,
54        gzip: impl ::core::convert::Into<bool>,
55    ) -> crate::system::io::compression::deflatestreamnative::DeflateStreamNative {
56        unsafe {
57            ::unity::il2cpp_call!((::unity::module_base()+0x35584f0usize)as*mut u8,crate::system::io::compression::deflatestreamnative::DeflateStreamNative;
58(crate::system::io::stream::Stream)::core::convert::Into::into(compressed_stream),(crate::system::io::compression::compressionmode::CompressionMode)::core::convert::Into::into(mode),(bool)::core::convert::Into::into(gzip))
59        }
60    }
61
62    #[doc = "`UnmanagedRead(::unity::IntPtr, i32, ::unity::IntPtr)` overload"]
63    pub fn unmanaged_read(
64        buffer: impl ::core::convert::Into<::unity::IntPtr>,
65        length: impl ::core::convert::Into<i32>,
66        data: impl ::core::convert::Into<::unity::IntPtr>,
67    ) -> i32 {
68        unsafe {
69            ::unity::il2cpp_call!((::unity::module_base()+0x35598c0usize)as*mut u8,i32;
70(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length),(::unity::IntPtr)::core::convert::Into::into(data))
71        }
72    }
73
74    #[doc = "`UnmanagedWrite(::unity::IntPtr, i32, ::unity::IntPtr)` overload"]
75    pub fn unmanaged_write(
76        buffer: impl ::core::convert::Into<::unity::IntPtr>,
77        length: impl ::core::convert::Into<i32>,
78        data: impl ::core::convert::Into<::unity::IntPtr>,
79    ) -> i32 {
80        unsafe {
81            ::unity::il2cpp_call!((::unity::module_base()+0x3559980usize)as*mut u8,i32;
82(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length),(::unity::IntPtr)::core::convert::Into::into(data))
83        }
84    }
85
86    #[doc = "`CheckResult(i32, ::unity::Il2CppString)` overload"]
87    pub fn check_result(result: impl ::core::convert::Into<i32>, r#where: impl ::core::convert::Into<::unity::Il2CppString>) -> () {
88        unsafe {
89            ::unity::il2cpp_call!((::unity::module_base()+0x3559c10usize)as*mut u8,();
90(i32)::core::convert::Into::into(result),(::unity::Il2CppString)::core::convert::Into::into(r#where))
91        }
92    }
93
94    #[doc = "`CreateZStream(crate::system::io::compression::compressionmode::CompressionMode, bool, crate::system::io::compression::deflatestreamnative::DeflateStreamNative_UnmanagedReadOrWrite, ::unity::IntPtr)` overload"]
95    pub fn create_z_stream(
96        compress: impl ::core::convert::Into<crate::system::io::compression::compressionmode::CompressionMode>,
97        gzip: impl ::core::convert::Into<bool>,
98        feeder: impl ::core::convert::Into<crate::system::io::compression::deflatestreamnative::DeflateStreamNative_UnmanagedReadOrWrite>,
99        data: impl ::core::convert::Into<::unity::IntPtr>,
100    ) -> crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle {
101        unsafe {
102            ::unity::il2cpp_call!((::unity::module_base()+0x3559a50usize)as*mut u8,crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle;
103(crate::system::io::compression::compressionmode::CompressionMode)::core::convert::Into::into(compress),(bool)::core::convert::Into::into(gzip),(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_UnmanagedReadOrWrite)::core::convert::Into::into(feeder),(::unity::IntPtr)::core::convert::Into::into(data))
104        }
105    }
106
107    #[doc = "`CloseZStream(::unity::IntPtr)` overload"]
108    pub fn close_z_stream(stream: impl ::core::convert::Into<::unity::IntPtr>) -> i32 {
109        unsafe {
110            ::unity::il2cpp_call!((::unity::module_base()+0x355a0e0usize)as*mut u8,i32;
111(::unity::IntPtr)::core::convert::Into::into(stream))
112        }
113    }
114
115    #[doc = "`Flush(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle)` overload"]
116    pub fn flush_2(
117        stream: impl ::core::convert::Into<crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle>,
118    ) -> i32 {
119        unsafe {
120            ::unity::il2cpp_call!((::unity::module_base()+0x3559ba0usize)as*mut u8,i32;
121(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle)::core::convert::Into::into(stream))
122        }
123    }
124
125    #[doc = "`ReadZStream(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle, ::unity::IntPtr, i32)` overload"]
126    pub fn read_z_stream_2(
127        stream: impl ::core::convert::Into<crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle>,
128        buffer: impl ::core::convert::Into<::unity::IntPtr>,
129        length: impl ::core::convert::Into<i32>,
130    ) -> i32 {
131        unsafe {
132            ::unity::il2cpp_call!((::unity::module_base()+0x3559d10usize)as*mut u8,i32;
133(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle)::core::convert::Into::into(stream),(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
134        }
135    }
136
137    #[doc = "`WriteZStream(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle, ::unity::IntPtr, i32)` overload"]
138    pub fn write_z_stream_2(
139        stream: impl ::core::convert::Into<crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle>,
140        buffer: impl ::core::convert::Into<::unity::IntPtr>,
141        length: impl ::core::convert::Into<i32>,
142    ) -> i32 {
143        unsafe {
144            ::unity::il2cpp_call!((::unity::module_base()+0x3559d90usize)as*mut u8,i32;
145(crate::system::io::compression::deflatestreamnative::DeflateStreamNative_SafeDeflateStreamHandle)::core::convert::Into::into(stream),(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
146        }
147    }
148}
149
150#[cfg(feature = "system-io-compression-deflatestreamnative")]
151pub trait IDeflateStreamNativeMethods: IDeflateStreamNative {
152    #[doc = "`.ctor()` overload"]
153    fn ctor(self) -> () {
154        unsafe {
155            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
156            ::unity::il2cpp_call!((::unity::module_base()+0x3559a40usize)as*mut u8,();
157(DeflateStreamNative)__receiver)
158        }
159    }
160    #[doc = "`Finalize()` overload"]
161    fn finalize(self) -> () {
162        unsafe {
163            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
164            {
165                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
166                let __vi = *__vt.get(1usize).unwrap_or_else(|| {
167                    panic!(
168                        "unity: virtual slot {}
169 out of range (vtable len {}
170) on the runtime class behind {}
171 (method `{}
172`)",
173                        1usize,
174                        __vt.len(),
175                        <DeflateStreamNative as ::unity::ClassIdentity>::NAME,
176                        "Finalize",
177                    )
178                });
179                let __inner: extern "C" fn(DeflateStreamNative, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__vi.method_ptr);
180                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
181                __inner(__receiver, __mi)
182            }
183        }
184    }
185    #[doc = "`Dispose(bool)` overload"]
186    fn dispose(self, disposing: impl ::core::convert::Into<bool>) -> () {
187        unsafe {
188            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
189            ::unity::il2cpp_call!((::unity::module_base()+0x3558760usize)as*mut u8,();
190(DeflateStreamNative)__receiver,(bool)::core::convert::Into::into(disposing))
191        }
192    }
193    #[doc = "`Flush()` overload"]
194    fn flush(self) -> () {
195        unsafe {
196            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
197            ::unity::il2cpp_call!((::unity::module_base()+0x3558ee0usize)as*mut u8,();
198(DeflateStreamNative)__receiver)
199        }
200    }
201    #[doc = "`ReadZStream(::unity::IntPtr, i32)` overload"]
202    fn read_z_stream(self, buffer: impl ::core::convert::Into<::unity::IntPtr>, length: impl ::core::convert::Into<i32>) -> i32 {
203        unsafe {
204            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
205            ::unity::il2cpp_call!((::unity::module_base()+0x3558890usize)as*mut u8,i32;
206(DeflateStreamNative)__receiver,(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
207        }
208    }
209    #[doc = "`WriteZStream(::unity::IntPtr, i32)` overload"]
210    fn write_z_stream(self, buffer: impl ::core::convert::Into<::unity::IntPtr>, length: impl ::core::convert::Into<i32>) -> () {
211        unsafe {
212            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
213            ::unity::il2cpp_call!((::unity::module_base()+0x3558b90usize)as*mut u8,();
214(DeflateStreamNative)__receiver,(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
215        }
216    }
217    #[doc = "`UnmanagedRead(::unity::IntPtr, i32)` overload"]
218    fn unmanaged_read_2(self, buffer: impl ::core::convert::Into<::unity::IntPtr>, length: impl ::core::convert::Into<i32>) -> i32 {
219        unsafe {
220            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
221            ::unity::il2cpp_call!((::unity::module_base()+0x3559e10usize)as*mut u8,i32;
222(DeflateStreamNative)__receiver,(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
223        }
224    }
225    #[doc = "`UnmanagedWrite(::unity::IntPtr, i32)` overload"]
226    fn unmanaged_write_2(self, buffer: impl ::core::convert::Into<::unity::IntPtr>, length: impl ::core::convert::Into<i32>) -> i32 {
227        unsafe {
228            let __receiver = <DeflateStreamNative as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
229            ::unity::il2cpp_call!((::unity::module_base()+0x3559f60usize)as*mut u8,i32;
230(DeflateStreamNative)__receiver,(::unity::IntPtr)::core::convert::Into::into(buffer),(i32)::core::convert::Into::into(length))
231        }
232    }
233}
234
235#[cfg(feature = "system-io-compression-deflatestreamnative")]
236impl<__T: IDeflateStreamNative> IDeflateStreamNativeMethods for __T {}
237
238#[cfg(feature = "system-io-compression-deflatestreamnative")]
239impl DeflateStreamNative {
240    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
241        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
242    }
243
244    pub fn create_method_info() -> &'static ::unity::il2cpp::MethodInfo {
245        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
246    }
247
248    pub fn finalize_method_info() -> &'static ::unity::il2cpp::MethodInfo {
249        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
250    }
251
252    pub fn dispose_method_info() -> &'static ::unity::il2cpp::MethodInfo {
253        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
254    }
255
256    pub fn flush_method_info() -> &'static ::unity::il2cpp::MethodInfo {
257        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
258    }
259
260    pub fn read_z_stream_method_info() -> &'static ::unity::il2cpp::MethodInfo {
261        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
262    }
263
264    pub fn write_z_stream_method_info() -> &'static ::unity::il2cpp::MethodInfo {
265        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
266    }
267
268    pub fn unmanaged_read_method_info() -> &'static ::unity::il2cpp::MethodInfo {
269        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
270    }
271
272    pub fn unmanaged_read_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
273        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
274    }
275
276    pub fn unmanaged_write_method_info() -> &'static ::unity::il2cpp::MethodInfo {
277        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
278    }
279
280    pub fn unmanaged_write_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
281        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
282    }
283
284    pub fn check_result_method_info() -> &'static ::unity::il2cpp::MethodInfo {
285        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
286    }
287
288    pub fn create_z_stream_method_info() -> &'static ::unity::il2cpp::MethodInfo {
289        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[12]
290    }
291
292    pub fn close_z_stream_method_info() -> &'static ::unity::il2cpp::MethodInfo {
293        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[13]
294    }
295
296    pub fn flush_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
297        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[14]
298    }
299
300    pub fn read_z_stream_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
301        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[15]
302    }
303
304    pub fn write_z_stream_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
305        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[16]
306    }
307}
308
309#[cfg(feature = "system-io-compression-deflatestreamnative")]
310impl DeflateStreamNative {
311    #[doc = "Direct (non-virtual) call to `DeflateStreamNative`'s own `Finalize`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
312    pub unsafe fn finalize(this: impl ::core::convert::Into<::unity::IlInstance>) -> () {
313        let __mi = Self::finalize_method_info();
314        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
315        __inner(this.into(), ::core::option::Option::None)
316    }
317}
318
319#[cfg(feature = "system-io-compression-deflatestreamnative")]
320impl DeflateStreamNative {
321    #[doc = "`.ctor()` — no args"]
322    pub fn new() -> Self {
323        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
324            panic!(
325                "{}
326::{}
327 failed to instantiate",
328                ::core::stringify!(DeflateStreamNative),
329                ::core::stringify!(new),
330            )
331        });
332        <Self as IDeflateStreamNativeMethods>::ctor(this);
333        this
334    }
335}
336
337#[cfg(feature = "system-io-compression-deflatestreamnative")]
338pub trait IDeflateStreamNative_UnmanagedReadOrWriteMethods: IDeflateStreamNative_UnmanagedReadOrWrite {
339    #[doc = "`.ctor(crate::system::object::Object, ::unity::IntPtr)` overload"]
340    fn ctor(self, object: impl ::core::convert::Into<crate::system::object::Object>, method: impl ::core::convert::Into<::unity::IntPtr>) -> () {
341        unsafe {
342            let __receiver = <DeflateStreamNative_UnmanagedReadOrWrite as ::unity::FromIlInstance>::from_il_instance(
343                <Self as ::unity::SystemObject>::as_instance(self),
344            );
345            ::unity::il2cpp_call!((::unity::module_base()+0x2a7fd20usize)as*mut u8,();
346(DeflateStreamNative_UnmanagedReadOrWrite)__receiver,(crate::system::object::Object)::core::convert::Into::into(object),(::unity::IntPtr)::core::convert::Into::into(method))
347        }
348    }
349    #[doc = "`Invoke(::unity::IntPtr, i32, ::unity::IntPtr)` overload"]
350    fn invoke(
351        self,
352        buffer: impl ::core::convert::Into<::unity::IntPtr>,
353        length: impl ::core::convert::Into<i32>,
354        data: impl ::core::convert::Into<::unity::IntPtr>,
355    ) -> i32 {
356        unsafe {
357            let __receiver = <DeflateStreamNative_UnmanagedReadOrWrite as ::unity::FromIlInstance>::from_il_instance(
358                <Self as ::unity::SystemObject>::as_instance(self),
359            );
360            {
361                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
362                let __vi = *__vt.get(13usize).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                        13usize,
370                        __vt.len(),
371                        <DeflateStreamNative_UnmanagedReadOrWrite as ::unity::ClassIdentity>::NAME,
372                        "Invoke",
373                    )
374                });
375                let __inner: extern "C" fn(
376                    DeflateStreamNative_UnmanagedReadOrWrite,
377                    ::unity::IntPtr,
378                    i32,
379                    ::unity::IntPtr,
380                    ::unity::OptionalMethod,
381                ) -> i32 = ::core::mem::transmute(__vi.method_ptr);
382                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
383                __inner(
384                    __receiver,
385                    ::core::convert::Into::into(buffer),
386                    ::core::convert::Into::into(length),
387                    ::core::convert::Into::into(data),
388                    __mi,
389                )
390            }
391        }
392    }
393}
394
395#[cfg(feature = "system-io-compression-deflatestreamnative")]
396impl<__T: IDeflateStreamNative_UnmanagedReadOrWrite> IDeflateStreamNative_UnmanagedReadOrWriteMethods for __T {}
397
398#[cfg(feature = "system-io-compression-deflatestreamnative")]
399impl DeflateStreamNative_UnmanagedReadOrWrite {
400    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
401        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
402    }
403
404    pub fn invoke_method_info() -> &'static ::unity::il2cpp::MethodInfo {
405        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
406    }
407}
408
409#[cfg(feature = "system-io-compression-deflatestreamnative")]
410impl DeflateStreamNative_UnmanagedReadOrWrite {
411    #[doc = "Direct (non-virtual) call to `DeflateStreamNative_UnmanagedReadOrWrite`'s own `Invoke`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
412    pub unsafe fn invoke(this: impl ::core::convert::Into<::unity::IlInstance>, buffer: ::unity::IntPtr, length: i32, data: ::unity::IntPtr) -> i32 {
413        let __mi = Self::invoke_method_info();
414        let __inner: extern "C" fn(::unity::IlInstance, ::unity::IntPtr, i32, ::unity::IntPtr, ::unity::OptionalMethod) -> i32 =
415            ::core::mem::transmute(__mi.method_ptr);
416        __inner(this.into(), buffer, length, data, ::core::option::Option::None)
417    }
418}
419
420#[cfg(feature = "system-io-compression-deflatestreamnative")]
421impl DeflateStreamNative_UnmanagedReadOrWrite {
422    #[doc = "`.ctor(crate::system::object::Object, ::unity::IntPtr)` — overload selector"]
423    pub fn new(object: crate::system::object::Object, method: ::unity::IntPtr) -> Self {
424        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
425            panic!(
426                "{}
427::{}
428 failed to instantiate",
429                ::core::stringify!(DeflateStreamNative_UnmanagedReadOrWrite),
430                ::core::stringify!(new),
431            )
432        });
433        <Self as IDeflateStreamNative_UnmanagedReadOrWriteMethods>::ctor(this, object, method);
434        this
435    }
436}
437
438#[cfg(feature = "system-io-compression-deflatestreamnative")]
439pub trait IDeflateStreamNative_SafeDeflateStreamHandleMethods: IDeflateStreamNative_SafeDeflateStreamHandle {
440    #[doc = "`get_IsInvalid()` overload"]
441    fn get_is_invalid(self) -> bool {
442        unsafe {
443            let __receiver = <DeflateStreamNative_SafeDeflateStreamHandle as ::unity::FromIlInstance>::from_il_instance(
444                <Self as ::unity::SystemObject>::as_instance(self),
445            );
446            {
447                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
448                let __vi = *__vt.get(5usize).unwrap_or_else(|| {
449                    panic!(
450                        "unity: virtual slot {}
451 out of range (vtable len {}
452) on the runtime class behind {}
453 (method `{}
454`)",
455                        5usize,
456                        __vt.len(),
457                        <DeflateStreamNative_SafeDeflateStreamHandle as ::unity::ClassIdentity>::NAME,
458                        "get_IsInvalid",
459                    )
460                });
461                let __inner: extern "C" fn(DeflateStreamNative_SafeDeflateStreamHandle, ::unity::OptionalMethod) -> bool =
462                    ::core::mem::transmute(__vi.method_ptr);
463                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
464                __inner(__receiver, __mi)
465            }
466        }
467    }
468    #[doc = "`.ctor()` overload"]
469    fn ctor(self) -> () {
470        unsafe {
471            let __receiver = <DeflateStreamNative_SafeDeflateStreamHandle as ::unity::FromIlInstance>::from_il_instance(
472                <Self as ::unity::SystemObject>::as_instance(self),
473            );
474            ::unity::il2cpp_call!((::unity::module_base()+0x2a7fcb0usize)as*mut u8,();
475(DeflateStreamNative_SafeDeflateStreamHandle)__receiver)
476        }
477    }
478    #[doc = "`ReleaseHandle()` overload"]
479    fn release_handle(self) -> bool {
480        unsafe {
481            let __receiver = <DeflateStreamNative_SafeDeflateStreamHandle as ::unity::FromIlInstance>::from_il_instance(
482                <Self as ::unity::SystemObject>::as_instance(self),
483            );
484            {
485                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
486                let __vi = *__vt.get(7usize).unwrap_or_else(|| {
487                    panic!(
488                        "unity: virtual slot {}
489 out of range (vtable len {}
490) on the runtime class behind {}
491 (method `{}
492`)",
493                        7usize,
494                        __vt.len(),
495                        <DeflateStreamNative_SafeDeflateStreamHandle as ::unity::ClassIdentity>::NAME,
496                        "ReleaseHandle",
497                    )
498                });
499                let __inner: extern "C" fn(DeflateStreamNative_SafeDeflateStreamHandle, ::unity::OptionalMethod) -> bool =
500                    ::core::mem::transmute(__vi.method_ptr);
501                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
502                __inner(__receiver, __mi)
503            }
504        }
505    }
506}
507
508#[cfg(feature = "system-io-compression-deflatestreamnative")]
509impl<__T: IDeflateStreamNative_SafeDeflateStreamHandle> IDeflateStreamNative_SafeDeflateStreamHandleMethods for __T {}
510
511#[cfg(feature = "system-io-compression-deflatestreamnative")]
512impl DeflateStreamNative_SafeDeflateStreamHandle {
513    pub fn get_is_invalid_method_info() -> &'static ::unity::il2cpp::MethodInfo {
514        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
515    }
516
517    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
518        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
519    }
520
521    pub fn release_handle_method_info() -> &'static ::unity::il2cpp::MethodInfo {
522        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
523    }
524}
525
526#[cfg(feature = "system-io-compression-deflatestreamnative")]
527impl DeflateStreamNative_SafeDeflateStreamHandle {
528    #[doc = "Direct (non-virtual) call to `DeflateStreamNative_SafeDeflateStreamHandle`'s own `get_IsInvalid`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
529    pub unsafe fn get_is_invalid(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
530        let __mi = Self::get_is_invalid_method_info();
531        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
532        __inner(this.into(), ::core::option::Option::None)
533    }
534
535    #[doc = "Direct (non-virtual) call to `DeflateStreamNative_SafeDeflateStreamHandle`'s own `ReleaseHandle`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
536    pub unsafe fn release_handle(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
537        let __mi = Self::release_handle_method_info();
538        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
539        __inner(this.into(), ::core::option::Option::None)
540    }
541}
542
543#[cfg(feature = "system-io-compression-deflatestreamnative")]
544impl DeflateStreamNative_SafeDeflateStreamHandle {
545    #[doc = "`.ctor()` — no args"]
546    pub fn new() -> Self {
547        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
548            panic!(
549                "{}
550::{}
551 failed to instantiate",
552                ::core::stringify!(DeflateStreamNative_SafeDeflateStreamHandle),
553                ::core::stringify!(new),
554            )
555        });
556        <Self as IDeflateStreamNative_SafeDeflateStreamHandleMethods>::ctor(this);
557        this
558    }
559}
560
561#[cfg(feature = "system-io-compression-deflatestreamnative")]
562#[doc(hidden)]
563pub mod prelude {
564    pub use super::{
565        DeflateStreamNative, DeflateStreamNative_SafeDeflateStreamHandle, DeflateStreamNative_UnmanagedReadOrWrite, IDeflateStreamNative,
566        IDeflateStreamNativeMethods, IDeflateStreamNative_SafeDeflateStreamHandle, IDeflateStreamNative_SafeDeflateStreamHandleMethods,
567        IDeflateStreamNative_UnmanagedReadOrWrite, IDeflateStreamNative_UnmanagedReadOrWriteMethods,
568    };
569    #[cfg(feature = "system-delegate")]
570    pub use crate::system::delegate::IDelegateMethods;
571    #[cfg(feature = "system-multicastdelegate")]
572    pub use crate::system::multicastdelegate::IMulticastDelegateMethods;
573    #[cfg(feature = "system-object")]
574    pub use crate::system::object::IObjectMethods;
575    pub use crate::system::{delegate::IDelegate, multicastdelegate::IMulticastDelegate, object::IObject};
576}