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 MLUpdateContext;
);
extern_conformance!(
unsafe impl NSObjectProtocol for MLUpdateContext {}
);
impl MLUpdateContext {
extern_methods!(
#[cfg(all(feature = "MLTask", feature = "MLUpdateTask"))]
#[unsafe(method(task))]
#[unsafe(method_family = none)]
pub unsafe fn task(&self) -> Retained<MLUpdateTask>;
#[cfg(all(feature = "MLModel", feature = "MLWritable"))]
#[unsafe(method(model))]
#[unsafe(method_family = none)]
pub unsafe fn model(&self) -> Retained<MLModel>;
#[cfg(feature = "MLUpdateProgressEvent")]
#[unsafe(method(event))]
#[unsafe(method_family = none)]
pub unsafe fn event(&self) -> MLUpdateProgressEvent;
#[cfg(all(feature = "MLKey", feature = "MLMetricKey"))]
#[unsafe(method(metrics))]
#[unsafe(method_family = none)]
pub unsafe fn metrics(&self) -> Retained<NSDictionary<MLMetricKey, AnyObject>>;
#[cfg(all(feature = "MLKey", feature = "MLParameterKey"))]
#[unsafe(method(parameters))]
#[unsafe(method_family = none)]
pub unsafe fn parameters(&self) -> Retained<NSDictionary<MLParameterKey, AnyObject>>;
);
}
impl MLUpdateContext {
extern_methods!(
#[unsafe(method(init))]
#[unsafe(method_family = init)]
pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
#[unsafe(method(new))]
#[unsafe(method_family = new)]
pub unsafe fn new() -> Retained<Self>;
);
}