//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use crate::common::*;
use crate::CloudKit::*;
use crate::CoreLocation::*;
use crate::Foundation::*;

extern_class!(
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "CloudKit_CKDatabaseOperation")]
    pub struct CKDatabaseOperation;

    #[cfg(feature = "CloudKit_CKDatabaseOperation")]
    unsafe impl ClassType for CKDatabaseOperation {
        #[inherits(NSOperation, NSObject)]
        type Super = CKOperation;
        type Mutability = InteriorMutable;
    }
);

#[cfg(feature = "CloudKit_CKDatabaseOperation")]
unsafe impl NSObjectProtocol for CKDatabaseOperation {}

extern_methods!(
    #[cfg(feature = "CloudKit_CKDatabaseOperation")]
    unsafe impl CKDatabaseOperation {
        #[cfg(feature = "CloudKit_CKDatabase")]
        #[method_id(@__retain_semantics Other database)]
        pub unsafe fn database(&self) -> Option<Id<CKDatabase>>;

        #[cfg(feature = "CloudKit_CKDatabase")]
        #[method(setDatabase:)]
        pub unsafe fn setDatabase(&self, database: Option<&CKDatabase>);
    }
);

extern_methods!(
    /// Methods declared on superclass `CKOperation`
    #[cfg(feature = "CloudKit_CKDatabaseOperation")]
    unsafe impl CKDatabaseOperation {
        #[method_id(@__retain_semantics Init init)]
        pub unsafe fn init(this: Option<Allocated<Self>>) -> Id<Self>;
    }
);

extern_methods!(
    /// Methods declared on superclass `NSObject`
    #[cfg(feature = "CloudKit_CKDatabaseOperation")]
    unsafe impl CKDatabaseOperation {
        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new() -> Id<Self>;
    }
);
