use core::ffi::*;
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
#[unsafe(super(NSObject))]
#[derive(Debug, PartialEq, Eq, Hash)]
pub struct UIImageAsset;
);
unsafe impl Send for UIImageAsset {}
unsafe impl Sync for UIImageAsset {}
extern_conformance!(
unsafe impl NSCoding for UIImageAsset {}
);
extern_conformance!(
unsafe impl NSObjectProtocol for UIImageAsset {}
);
extern_conformance!(
unsafe impl NSSecureCoding for UIImageAsset {}
);
impl UIImageAsset {
extern_methods!(
#[unsafe(method(init))]
#[unsafe(method_family = init)]
pub fn init(this: Allocated<Self>) -> Retained<Self>;
#[unsafe(method(initWithCoder:))]
#[unsafe(method_family = init)]
pub unsafe fn initWithCoder(
this: Allocated<Self>,
coder: &NSCoder,
) -> Option<Retained<Self>>;
#[cfg(all(feature = "UIImage", feature = "UIImageConfiguration"))]
#[unsafe(method(imageWithConfiguration:))]
#[unsafe(method_family = none)]
pub fn imageWithConfiguration(
&self,
configuration: &UIImageConfiguration,
) -> Retained<UIImage>;
#[cfg(all(feature = "UIImage", feature = "UIImageConfiguration"))]
#[unsafe(method(registerImage:withConfiguration:))]
#[unsafe(method_family = none)]
pub fn registerImage_withConfiguration(
&self,
image: &UIImage,
configuration: &UIImageConfiguration,
);
#[cfg(feature = "UIImageConfiguration")]
#[unsafe(method(unregisterImageWithConfiguration:))]
#[unsafe(method_family = none)]
pub fn unregisterImageWithConfiguration(&self, configuration: &UIImageConfiguration);
#[cfg(all(feature = "UIImage", feature = "UITraitCollection"))]
#[unsafe(method(imageWithTraitCollection:))]
#[unsafe(method_family = none)]
pub fn imageWithTraitCollection(
&self,
trait_collection: &UITraitCollection,
) -> Retained<UIImage>;
#[cfg(all(feature = "UIImage", feature = "UITraitCollection"))]
#[unsafe(method(registerImage:withTraitCollection:))]
#[unsafe(method_family = none)]
pub fn registerImage_withTraitCollection(
&self,
image: &UIImage,
trait_collection: &UITraitCollection,
);
#[cfg(feature = "UITraitCollection")]
#[unsafe(method(unregisterImageWithTraitCollection:))]
#[unsafe(method_family = none)]
pub fn unregisterImageWithTraitCollection(&self, trait_collection: &UITraitCollection);
);
}
impl UIImageAsset {
extern_methods!(
#[unsafe(method(new))]
#[unsafe(method_family = new)]
pub fn new() -> Retained<Self>;
);
}
impl DefaultRetained for UIImageAsset {
#[inline]
fn default_retained() -> Retained<Self> {
Self::new()
}
}