icrate 0.1.2

Bindings to Apple's frameworks
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use crate::common::*;
use crate::CoreData::*;
use crate::Foundation::*;

extern_static!(NSMigrationManagerKey: &'static NSString);

extern_static!(NSMigrationSourceObjectKey: &'static NSString);

extern_static!(NSMigrationDestinationObjectKey: &'static NSString);

extern_static!(NSMigrationEntityMappingKey: &'static NSString);

extern_static!(NSMigrationPropertyMappingKey: &'static NSString);

extern_static!(NSMigrationEntityPolicyKey: &'static NSString);

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

    #[cfg(feature = "CoreData_NSEntityMigrationPolicy")]
    unsafe impl ClassType for NSEntityMigrationPolicy {
        type Super = NSObject;
        type Mutability = InteriorMutable;
    }
);

#[cfg(feature = "CoreData_NSEntityMigrationPolicy")]
unsafe impl NSObjectProtocol for NSEntityMigrationPolicy {}

extern_methods!(
    #[cfg(feature = "CoreData_NSEntityMigrationPolicy")]
    unsafe impl NSEntityMigrationPolicy {
        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(beginEntityMapping:manager:error:_)]
        pub unsafe fn beginEntityMapping_manager_error(
            &self,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSManagedObject",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(createDestinationInstancesForSourceInstance:entityMapping:manager:error:_)]
        pub unsafe fn createDestinationInstancesForSourceInstance_entityMapping_manager_error(
            &self,
            s_instance: &NSManagedObject,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(endInstanceCreationForEntityMapping:manager:error:_)]
        pub unsafe fn endInstanceCreationForEntityMapping_manager_error(
            &self,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSManagedObject",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(createRelationshipsForDestinationInstance:entityMapping:manager:error:_)]
        pub unsafe fn createRelationshipsForDestinationInstance_entityMapping_manager_error(
            &self,
            d_instance: &NSManagedObject,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(endRelationshipCreationForEntityMapping:manager:error:_)]
        pub unsafe fn endRelationshipCreationForEntityMapping_manager_error(
            &self,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(performCustomValidationForEntityMapping:manager:error:_)]
        pub unsafe fn performCustomValidationForEntityMapping_manager_error(
            &self,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;

        #[cfg(all(
            feature = "CoreData_NSEntityMapping",
            feature = "CoreData_NSMigrationManager",
            feature = "Foundation_NSError"
        ))]
        #[method(endEntityMapping:manager:error:_)]
        pub unsafe fn endEntityMapping_manager_error(
            &self,
            mapping: &NSEntityMapping,
            manager: &NSMigrationManager,
        ) -> Result<(), Id<NSError>>;
    }
);

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

        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new() -> Id<Self>;
    }
);