objc2_virtualization/generated/
VZStorageDeviceConfiguration.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// Base class for a storage device configuration.
11    ///
12    /// VZStorageDeviceConfiguration should not be instantiated directly.
13    /// One of its subclasses like VZVirtioBlockDeviceConfiguration should be used instead.
14    ///
15    ///
16    /// See: VZNVMExpressControllerDeviceConfiguration
17    ///
18    /// See: VZUSBMassStorageDeviceConfiguration
19    ///
20    /// See: VZVirtioBlockDeviceConfiguration
21    ///
22    /// See also [Apple's documentation](https://developer.apple.com/documentation/virtualization/vzstoragedeviceconfiguration?language=objc)
23    #[unsafe(super(NSObject))]
24    #[derive(Debug, PartialEq, Eq, Hash)]
25    pub struct VZStorageDeviceConfiguration;
26);
27
28unsafe impl NSCopying for VZStorageDeviceConfiguration {}
29
30unsafe impl CopyingHelper for VZStorageDeviceConfiguration {
31    type Result = Self;
32}
33
34unsafe impl NSObjectProtocol for VZStorageDeviceConfiguration {}
35
36impl VZStorageDeviceConfiguration {
37    extern_methods!(
38        #[unsafe(method(new))]
39        #[unsafe(method_family = new)]
40        pub unsafe fn new() -> Retained<Self>;
41
42        #[unsafe(method(init))]
43        #[unsafe(method_family = init)]
44        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
45
46        #[cfg(feature = "VZStorageDeviceAttachment")]
47        /// Storage device attachment. Defines what local resource is exposed to the virtual machine as a disk.
48        ///
49        /// See: VZDiskImageStorageDeviceAttachment
50        #[unsafe(method(attachment))]
51        #[unsafe(method_family = none)]
52        pub unsafe fn attachment(&self) -> Retained<VZStorageDeviceAttachment>;
53    );
54}