engage/generated/system/io/
fileoptions.rs1#[cfg(feature = "system-io-fileoptions-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::system::{
9 object::{IObject, Object},
10 r#enum::{Enum, IEnum},
11 valuetype::{IValueType, ValueType},
12 };
13
14 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/system/io/fileoptions/FileOptions.md"))]
15 #[repr(C)]
16 #[derive(::core::clone::Clone, ::core::marker::Copy, ::core::fmt::Debug, ::core::cmp::PartialEq, ::core::cmp::Eq)]
17 pub struct FileOptions {
18 pub value: i32,
19 }
20 impl ::unity::ClassIdentity for FileOptions {
21 const NAME: &'static str = "FileOptions";
22 const NAMESPACE: &'static str = "System.IO";
23
24 fn class() -> ::unity::Class {
25 static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
26 *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
27 }
28 }
29 impl ::unity::IlType for FileOptions {
30 fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
31 &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
32 }
33 }
34 impl FileOptions {
35 pub fn none() -> Self {
36 Self { value: 0 }
37 }
38
39 pub fn encrypted() -> Self {
40 Self { value: 16384 }
41 }
42
43 pub fn delete_on_close() -> Self {
44 Self { value: 67108864 }
45 }
46
47 pub fn sequential_scan() -> Self {
48 Self { value: 134217728 }
49 }
50
51 pub fn random_access() -> Self {
52 Self { value: 268435456 }
53 }
54
55 pub fn asynchronous() -> Self {
56 Self { value: 1073741824 }
57 }
58
59 pub fn write_through() -> Self {
60 Self { value: -2147483648 }
61 }
62 }
63}
64
65#[cfg(feature = "system-io-fileoptions-types")]
66pub use __types::*;
67
68#[cfg(feature = "system-io-fileoptions")]
69#[doc(hidden)]
70pub mod prelude {
71 pub use super::FileOptions;
72 #[cfg(feature = "system-object")]
73 pub use crate::system::object::IObjectMethods;
74 #[cfg(feature = "system-enum")]
75 pub use crate::system::r#enum::IEnumMethods;
76 #[cfg(feature = "system-valuetype")]
77 pub use crate::system::valuetype::IValueTypeMethods;
78 pub use crate::system::{object::IObject, r#enum::IEnum, valuetype::IValueType};
79}