objc2-virtualization 0.3.2

Bindings to the Virtualization framework
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    /// Configuration of a paravirtualized network device of type Virtio Network Device.
    ///
    /// The communication channel used on the host is defined through the attachment. It is set with the VZNetworkDeviceConfiguration.attachment property.
    ///
    /// The configuration is only valid with valid MACAddress and attachment.
    ///
    ///
    /// See: VZVirtualMachineConfiguration.networkDevices
    ///
    /// See also [Apple's documentation](https://developer.apple.com/documentation/virtualization/vzvirtionetworkdeviceconfiguration?language=objc)
    #[unsafe(super(VZNetworkDeviceConfiguration, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "VZNetworkDeviceConfiguration")]
    pub struct VZVirtioNetworkDeviceConfiguration;
);

#[cfg(feature = "VZNetworkDeviceConfiguration")]
extern_conformance!(
    unsafe impl NSCopying for VZVirtioNetworkDeviceConfiguration {}
);

#[cfg(feature = "VZNetworkDeviceConfiguration")]
unsafe impl CopyingHelper for VZVirtioNetworkDeviceConfiguration {
    type Result = Self;
}

#[cfg(feature = "VZNetworkDeviceConfiguration")]
extern_conformance!(
    unsafe impl NSObjectProtocol for VZVirtioNetworkDeviceConfiguration {}
);

#[cfg(feature = "VZNetworkDeviceConfiguration")]
impl VZVirtioNetworkDeviceConfiguration {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
    );
}

/// Methods declared on superclass `VZNetworkDeviceConfiguration`.
#[cfg(feature = "VZNetworkDeviceConfiguration")]
impl VZVirtioNetworkDeviceConfiguration {
    extern_methods!(
        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}