Skip to main content

engage/generated/unity_engine/serialization/
formerlyserializedasattribute.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8
9    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/unity_engine/serialization/formerlyserializedasattribute/FormerlySerializedAsAttribute.md"))]
10    #[::unity::class(namespace = "UnityEngine.Serialization", name = "FormerlySerializedAsAttribute")]
11    pub struct FormerlySerializedAsAttribute {
12        #[offset(16)]
13        #[rename(name = "m_oldName")]
14        pub m_old_name: ::unity::Il2CppString,
15    }
16}
17
18#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute-types")]
19pub use __types::*;
20
21#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute")]
22pub trait IFormerlySerializedAsAttributeMethods: IFormerlySerializedAsAttribute {
23    #[doc = "`.ctor(::unity::Il2CppString)` overload"]
24    fn ctor(self, old_name: impl ::core::convert::Into<::unity::Il2CppString>) -> () {
25        unsafe {
26            let __receiver =
27                <FormerlySerializedAsAttribute as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
28            ::unity::il2cpp_call!((::unity::module_base()+0x2c4d990usize)as*mut u8,();
29(FormerlySerializedAsAttribute)__receiver,(::unity::Il2CppString)::core::convert::Into::into(old_name))
30        }
31    }
32}
33
34#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute")]
35impl<__T: IFormerlySerializedAsAttribute> IFormerlySerializedAsAttributeMethods for __T {}
36
37#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute")]
38impl FormerlySerializedAsAttribute {
39    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
40        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
41    }
42}
43
44#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute")]
45impl FormerlySerializedAsAttribute {
46    #[doc = "`.ctor(::unity::Il2CppString)` — overload selector"]
47    pub fn new(old_name: ::unity::Il2CppString) -> Self {
48        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
49            panic!(
50                "{}
51::{}
52 failed to instantiate",
53                ::core::stringify!(FormerlySerializedAsAttribute),
54                ::core::stringify!(new),
55            )
56        });
57        <Self as IFormerlySerializedAsAttributeMethods>::ctor(this, old_name);
58        this
59    }
60}
61
62#[cfg(feature = "unity_engine-serialization-formerlyserializedasattribute")]
63#[doc(hidden)]
64pub mod prelude {
65    pub use super::{FormerlySerializedAsAttribute, IFormerlySerializedAsAttribute, IFormerlySerializedAsAttributeMethods};
66}