//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::cell::UnsafeCell;
use core::ffi::*;
use core::marker::{PhantomData, PhantomPinned};
use core::ptr::NonNull;
#[cfg(feature = "objc2")]
use objc2::__framework_prelude::*;
use objc2_core_foundation::*;

use crate::*;

/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/icversion4number?language=objc)
pub const icVersion4Number: c_uint = 0x04000000;
/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsync_profile_install_entitlement?language=objc)
pub const COLORSYNC_PROFILE_INSTALL_ENTITLEMENT: &CStr = unsafe {
    CStr::from_bytes_with_nul_unchecked(b"com.apple.developer.ColorSync.profile.install\0")
};
/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsync_md5_length?language=objc)
pub const COLORSYNC_MD5_LENGTH: c_uint = 16;
/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsyncprofile?language=objc)
#[doc(alias = "ColorSyncProfileRef")]
#[repr(C)]
pub struct ColorSyncProfile {
    inner: [u8; 0],
    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
}

cf_type!(
    unsafe impl ColorSyncProfile {}
);
#[cfg(feature = "objc2")]
cf_objc2_type!(
    unsafe impl RefEncode<"ColorSyncProfile"> for ColorSyncProfile {}
);

/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsyncmutableprofile?language=objc)
#[doc(alias = "ColorSyncMutableProfileRef")]
#[repr(C)]
pub struct ColorSyncMutableProfile {
    inner: [u8; 0],
    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
}

cf_type!(
    unsafe impl ColorSyncMutableProfile: ColorSyncProfile {}
);
#[cfg(feature = "objc2")]
cf_objc2_type!(
    unsafe impl RefEncode<"ColorSyncProfile"> for ColorSyncMutableProfile {}
);

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericgrayprofile?language=objc)
    pub static kColorSyncGenericGrayProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericgraygamma22profile?language=objc)
    pub static kColorSyncGenericGrayGamma22Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericrgbprofile?language=objc)
    pub static kColorSyncGenericRGBProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericcmykprofile?language=objc)
    pub static kColorSyncGenericCMYKProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncdisplayp3profile?language=objc)
    pub static kColorSyncDisplayP3Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsrgbprofile?language=objc)
    pub static kColorSyncSRGBProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncadobergb1998profile?language=objc)
    pub static kColorSyncAdobeRGB1998Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericlabprofile?language=objc)
    pub static kColorSyncGenericLabProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncgenericxyzprofile?language=objc)
    pub static kColorSyncGenericXYZProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncacescglinearprofile?language=objc)
    pub static kColorSyncACESCGLinearProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncdcip3profile?language=objc)
    pub static kColorSyncDCIP3Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncitur709profile?language=objc)
    pub static kColorSyncITUR709Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncitur2020profile?language=objc)
    pub static kColorSyncITUR2020Profile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncrommrgbprofile?language=objc)
    pub static kColorSyncROMMRGBProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncwebsafecolorsprofile?language=objc)
    pub static kColorSyncWebSafeColorsProfile: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofileheader?language=objc)
    pub static kColorSyncProfileHeader: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofileclass?language=objc)
    pub static kColorSyncProfileClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofilecolorspace?language=objc)
    pub static kColorSyncProfileColorSpace: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofilepcs?language=objc)
    pub static kColorSyncProfilePCS: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofileurl?language=objc)
    pub static kColorSyncProfileURL: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofiledescription?language=objc)
    pub static kColorSyncProfileDescription: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofilemd5digest?language=objc)
    pub static kColorSyncProfileMD5Digest: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofileisvalid?language=objc)
    pub static kColorSyncProfileIsValid: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigatob0tag?language=objc)
    pub static kColorSyncSigAToB0Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigatob1tag?language=objc)
    pub static kColorSyncSigAToB1Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigatob2tag?language=objc)
    pub static kColorSyncSigAToB2Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigbtoa0tag?language=objc)
    pub static kColorSyncSigBToA0Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigbtoa1tag?language=objc)
    pub static kColorSyncSigBToA1Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigbtoa2tag?language=objc)
    pub static kColorSyncSigBToA2Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigcmykdata?language=objc)
    pub static kColorSyncSigCmykData: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiggraydata?language=objc)
    pub static kColorSyncSigGrayData: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiglabdata?language=objc)
    pub static kColorSyncSigLabData: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigrgbdata?language=objc)
    pub static kColorSyncSigRgbData: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigxyzdata?language=objc)
    pub static kColorSyncSigXYZData: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigabstractclass?language=objc)
    pub static kColorSyncSigAbstractClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigbluetrctag?language=objc)
    pub static kColorSyncSigBlueTRCTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigbluecoloranttag?language=objc)
    pub static kColorSyncSigBlueColorantTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigmediablackpointtag?language=objc)
    pub static kColorSyncSigMediaBlackPointTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigcopyrighttag?language=objc)
    pub static kColorSyncSigCopyrightTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigprofiledescriptiontag?language=objc)
    pub static kColorSyncSigProfileDescriptionTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigdevicemodeldesctag?language=objc)
    pub static kColorSyncSigDeviceModelDescTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigdevicemfgdesctag?language=objc)
    pub static kColorSyncSigDeviceMfgDescTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiggreentrctag?language=objc)
    pub static kColorSyncSigGreenTRCTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiggreencoloranttag?language=objc)
    pub static kColorSyncSigGreenColorantTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiggamuttag?language=objc)
    pub static kColorSyncSigGamutTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiggraytrctag?language=objc)
    pub static kColorSyncSigGrayTRCTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiglinkclass?language=objc)
    pub static kColorSyncSigLinkClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigdisplayclass?language=objc)
    pub static kColorSyncSigDisplayClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsignamedcolor2tag?language=objc)
    pub static kColorSyncSigNamedColor2Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsignamedcolorclass?language=objc)
    pub static kColorSyncSigNamedColorClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigpreview0tag?language=objc)
    pub static kColorSyncSigPreview0Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigpreview1tag?language=objc)
    pub static kColorSyncSigPreview1Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigpreview2tag?language=objc)
    pub static kColorSyncSigPreview2Tag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigoutputclass?language=objc)
    pub static kColorSyncSigOutputClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigprofilesequencedesctag?language=objc)
    pub static kColorSyncSigProfileSequenceDescTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigredtrctag?language=objc)
    pub static kColorSyncSigRedTRCTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigredcoloranttag?language=objc)
    pub static kColorSyncSigRedColorantTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsiginputclass?language=objc)
    pub static kColorSyncSigInputClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigcolorspaceclass?language=objc)
    pub static kColorSyncSigColorSpaceClass: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigtechnologytag?language=objc)
    pub static kColorSyncSigTechnologyTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigviewingconditionstag?language=objc)
    pub static kColorSyncSigViewingConditionsTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigviewingconddesctag?language=objc)
    pub static kColorSyncSigViewingCondDescTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncsigmediawhitepointtag?language=objc)
    pub static kColorSyncSigMediaWhitePointTag: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofilecomputerdomain?language=objc)
    pub static kColorSyncProfileComputerDomain: &'static CFString;
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofileuserdomain?language=objc)
    pub static kColorSyncProfileUserDomain: &'static CFString;
}

unsafe impl ConcreteType for ColorSyncProfile {
    #[doc(alias = "ColorSyncProfileGetTypeID")]
    #[inline]
    fn type_id() -> CFTypeID {
        extern "C-unwind" {
            fn ColorSyncProfileGetTypeID() -> CFTypeID;
        }
        unsafe { ColorSyncProfileGetTypeID() }
    }
}

impl ColorSyncProfile {
    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileCreate")]
    #[inline]
    pub unsafe fn new(
        data: &CFData,
        error: *mut *mut CFError,
    ) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreate(
                data: &CFData,
                error: *mut *mut CFError,
            ) -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreate(data, error) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileCreateWithURL")]
    #[inline]
    pub unsafe fn with_url(
        url: &CFURL,
        error: *mut *mut CFError,
    ) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateWithURL(
                url: &CFURL,
                error: *mut *mut CFError,
            ) -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateWithURL(url, error) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    #[doc(alias = "ColorSyncProfileCreateWithName")]
    #[inline]
    pub unsafe fn with_name(name: &CFString) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateWithName(name: &CFString)
                -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateWithName(name) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    #[doc(alias = "ColorSyncProfileCreateWithDisplayID")]
    #[inline]
    pub unsafe fn with_display_id(display_id: u32) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateWithDisplayID(
                display_id: u32,
            ) -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateWithDisplayID(display_id) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    /// # Safety
    ///
    /// `profile_id` should be of the correct type.
    #[doc(alias = "ColorSyncProfileCreateDeviceProfile")]
    #[inline]
    pub unsafe fn new_device_profile(
        device_class: &CFString,
        device_id: &CFUUID,
        profile_id: &CFType,
    ) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateDeviceProfile(
                device_class: &CFString,
                device_id: &CFUUID,
                profile_id: &CFType,
            ) -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret =
            unsafe { ColorSyncProfileCreateDeviceProfile(device_class, device_id, profile_id) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }
}

impl ColorSyncMutableProfile {
    #[doc(alias = "ColorSyncProfileCreateMutable")]
    #[inline]
    pub unsafe fn new() -> Option<CFRetained<ColorSyncMutableProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateMutable() -> Option<NonNull<ColorSyncMutableProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateMutable() };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    #[doc(alias = "ColorSyncProfileCreateMutableCopy")]
    #[inline]
    pub unsafe fn new_copy(prof: &ColorSyncProfile) -> Option<CFRetained<ColorSyncMutableProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateMutableCopy(
                prof: &ColorSyncProfile,
            ) -> Option<NonNull<ColorSyncMutableProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateMutableCopy(prof) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }
}

impl ColorSyncProfile {
    /// # Safety
    ///
    /// - `profile_info` generic must be of the correct type.
    /// - `options` generics must be of the correct type.
    #[doc(alias = "ColorSyncProfileCreateLink")]
    #[inline]
    pub unsafe fn new_link(
        profile_info: &CFArray,
        options: Option<&CFDictionary>,
    ) -> Option<CFRetained<ColorSyncProfile>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateLink(
                profile_info: &CFArray,
                options: Option<&CFDictionary>,
            ) -> Option<NonNull<ColorSyncProfile>>;
        }
        let ret = unsafe { ColorSyncProfileCreateLink(profile_info, options) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    /// # Safety
    ///
    /// - `errors` must be a valid pointer or null.
    /// - `warnings` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileVerify")]
    #[inline]
    pub unsafe fn verify(&self, errors: *mut *mut CFError, warnings: *mut *mut CFError) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileVerify(
                prof: &ColorSyncProfile,
                errors: *mut *mut CFError,
                warnings: *mut *mut CFError,
            ) -> bool;
        }
        unsafe { ColorSyncProfileVerify(self, errors, warnings) }
    }

    #[doc(alias = "ColorSyncProfileIsWideGamut")]
    #[inline]
    pub unsafe fn is_wide_gamut(&self) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileIsWideGamut(param1: &ColorSyncProfile) -> bool;
        }
        unsafe { ColorSyncProfileIsWideGamut(self) }
    }

    #[doc(alias = "ColorSyncProfileIsMatrixBased")]
    #[inline]
    pub unsafe fn is_matrix_based(&self) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileIsMatrixBased(param1: &ColorSyncProfile) -> bool;
        }
        unsafe { ColorSyncProfileIsMatrixBased(self) }
    }

    #[doc(alias = "ColorSyncProfileIsPQBased")]
    #[inline]
    pub unsafe fn is_pq_based(&self) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileIsPQBased(param1: &ColorSyncProfile) -> bool;
        }
        unsafe { ColorSyncProfileIsPQBased(self) }
    }

    #[doc(alias = "ColorSyncProfileIsHLGBased")]
    #[inline]
    pub unsafe fn is_hlg_based(&self) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileIsHLGBased(param1: &ColorSyncProfile) -> bool;
        }
        unsafe { ColorSyncProfileIsHLGBased(self) }
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileEstimateGammaWithDisplayID")]
    #[inline]
    pub unsafe fn estimate_gamma_with_display_id(
        display_id: i32,
        error: *mut *mut CFError,
    ) -> c_float {
        extern "C-unwind" {
            fn ColorSyncProfileEstimateGammaWithDisplayID(
                display_id: i32,
                error: *mut *mut CFError,
            ) -> c_float;
        }
        unsafe { ColorSyncProfileEstimateGammaWithDisplayID(display_id, error) }
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileEstimateGamma")]
    #[inline]
    pub unsafe fn estimate_gamma(&self, error: *mut *mut CFError) -> c_float {
        extern "C-unwind" {
            fn ColorSyncProfileEstimateGamma(
                prof: &ColorSyncProfile,
                error: *mut *mut CFError,
            ) -> c_float;
        }
        unsafe { ColorSyncProfileEstimateGamma(self, error) }
    }

    /// # Safety
    ///
    /// - `red_min` must be a valid pointer.
    /// - `red_max` must be a valid pointer.
    /// - `red_gamma` must be a valid pointer.
    /// - `green_min` must be a valid pointer.
    /// - `green_max` must be a valid pointer.
    /// - `green_gamma` must be a valid pointer.
    /// - `blue_min` must be a valid pointer.
    /// - `blue_max` must be a valid pointer.
    /// - `blue_gamma` must be a valid pointer.
    #[doc(alias = "ColorSyncProfileGetDisplayTransferFormulaFromVCGT")]
    #[inline]
    pub unsafe fn display_transfer_formula_from_vcgt(
        &self,
        red_min: NonNull<c_float>,
        red_max: NonNull<c_float>,
        red_gamma: NonNull<c_float>,
        green_min: NonNull<c_float>,
        green_max: NonNull<c_float>,
        green_gamma: NonNull<c_float>,
        blue_min: NonNull<c_float>,
        blue_max: NonNull<c_float>,
        blue_gamma: NonNull<c_float>,
    ) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileGetDisplayTransferFormulaFromVCGT(
                profile: &ColorSyncProfile,
                red_min: NonNull<c_float>,
                red_max: NonNull<c_float>,
                red_gamma: NonNull<c_float>,
                green_min: NonNull<c_float>,
                green_max: NonNull<c_float>,
                green_gamma: NonNull<c_float>,
                blue_min: NonNull<c_float>,
                blue_max: NonNull<c_float>,
                blue_gamma: NonNull<c_float>,
            ) -> bool;
        }
        unsafe {
            ColorSyncProfileGetDisplayTransferFormulaFromVCGT(
                self,
                red_min,
                red_max,
                red_gamma,
                green_min,
                green_max,
                green_gamma,
                blue_min,
                blue_max,
                blue_gamma,
            )
        }
    }

    /// # Safety
    ///
    /// `n_samples_per_channel` must be a valid pointer.
    #[doc(alias = "ColorSyncProfileCreateDisplayTransferTablesFromVCGT")]
    #[inline]
    pub unsafe fn display_transfer_tables_from_vcgt(
        &self,
        n_samples_per_channel: NonNull<usize>,
    ) -> Option<CFRetained<CFData>> {
        extern "C-unwind" {
            fn ColorSyncProfileCreateDisplayTransferTablesFromVCGT(
                profile: &ColorSyncProfile,
                n_samples_per_channel: NonNull<usize>,
            ) -> Option<NonNull<CFData>>;
        }
        let ret = unsafe {
            ColorSyncProfileCreateDisplayTransferTablesFromVCGT(self, n_samples_per_channel)
        };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }
}

/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsyncmd5?language=objc)
#[repr(C)]
#[derive(Clone, Copy, Debug, PartialEq)]
pub struct ColorSyncMD5 {
    pub digest: [u8; 16],
}

#[cfg(feature = "objc2")]
unsafe impl Encode for ColorSyncMD5 {
    const ENCODING: Encoding = Encoding::Struct("?", &[<[u8; 16]>::ENCODING]);
}

#[cfg(feature = "objc2")]
unsafe impl RefEncode for ColorSyncMD5 {
    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}

impl ColorSyncProfile {
    #[doc(alias = "ColorSyncProfileGetMD5")]
    #[inline]
    pub unsafe fn md_5(&self) -> ColorSyncMD5 {
        extern "C-unwind" {
            fn ColorSyncProfileGetMD5(prof: &ColorSyncProfile) -> ColorSyncMD5;
        }
        unsafe { ColorSyncProfileGetMD5(self) }
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileCopyData")]
    #[inline]
    pub unsafe fn data(&self, error: *mut *mut CFError) -> CFRetained<CFData> {
        extern "C-unwind" {
            fn ColorSyncProfileCopyData(
                prof: &ColorSyncProfile,
                error: *mut *mut CFError,
            ) -> Option<NonNull<CFData>>;
        }
        let ret = unsafe { ColorSyncProfileCopyData(self, error) };
        let ret =
            ret.expect("function was marked as returning non-null, but actually returned NULL");
        unsafe { CFRetained::from_raw(ret) }
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileGetURL")]
    #[inline]
    pub unsafe fn url(&self, error: *mut *mut CFError) -> CFRetained<CFURL> {
        extern "C-unwind" {
            fn ColorSyncProfileGetURL(
                prof: &ColorSyncProfile,
                error: *mut *mut CFError,
            ) -> Option<NonNull<CFURL>>;
        }
        let ret = unsafe { ColorSyncProfileGetURL(self, error) };
        let ret =
            ret.expect("function was marked as returning non-null, but actually returned NULL");
        unsafe { CFRetained::retain(ret) }
    }

    #[doc(alias = "ColorSyncProfileCopyHeader")]
    #[inline]
    pub unsafe fn header(&self) -> CFRetained<CFData> {
        extern "C-unwind" {
            fn ColorSyncProfileCopyHeader(prof: &ColorSyncProfile) -> Option<NonNull<CFData>>;
        }
        let ret = unsafe { ColorSyncProfileCopyHeader(self) };
        let ret =
            ret.expect("function was marked as returning non-null, but actually returned NULL");
        unsafe { CFRetained::from_raw(ret) }
    }
}

impl ColorSyncMutableProfile {
    #[doc(alias = "ColorSyncProfileSetHeader")]
    #[inline]
    pub unsafe fn set_header(&self, header: &CFData) {
        extern "C-unwind" {
            fn ColorSyncProfileSetHeader(prof: &ColorSyncMutableProfile, header: &CFData);
        }
        unsafe { ColorSyncProfileSetHeader(self, header) }
    }
}

impl ColorSyncProfile {
    #[doc(alias = "ColorSyncProfileCopyDescriptionString")]
    #[inline]
    pub unsafe fn description_string(&self) -> Option<CFRetained<CFString>> {
        extern "C-unwind" {
            fn ColorSyncProfileCopyDescriptionString(
                prof: &ColorSyncProfile,
            ) -> Option<NonNull<CFString>>;
        }
        let ret = unsafe { ColorSyncProfileCopyDescriptionString(self) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    #[doc(alias = "ColorSyncProfileCopyTagSignatures")]
    #[inline]
    pub unsafe fn tag_signatures(&self) -> Option<CFRetained<CFArray>> {
        extern "C-unwind" {
            fn ColorSyncProfileCopyTagSignatures(
                prof: &ColorSyncProfile,
            ) -> Option<NonNull<CFArray>>;
        }
        let ret = unsafe { ColorSyncProfileCopyTagSignatures(self) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }

    #[doc(alias = "ColorSyncProfileContainsTag")]
    #[inline]
    pub unsafe fn contains_tag(&self, signature: &CFString) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileContainsTag(prof: &ColorSyncProfile, signature: &CFString) -> bool;
        }
        unsafe { ColorSyncProfileContainsTag(self, signature) }
    }

    #[doc(alias = "ColorSyncProfileCopyTag")]
    #[inline]
    pub unsafe fn tag(&self, signature: &CFString) -> Option<CFRetained<CFData>> {
        extern "C-unwind" {
            fn ColorSyncProfileCopyTag(
                prof: &ColorSyncProfile,
                signature: &CFString,
            ) -> Option<NonNull<CFData>>;
        }
        let ret = unsafe { ColorSyncProfileCopyTag(self, signature) };
        ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
    }
}

impl ColorSyncMutableProfile {
    #[doc(alias = "ColorSyncProfileSetTag")]
    #[inline]
    pub unsafe fn set_tag(&self, signature: &CFString, data: &CFData) {
        extern "C-unwind" {
            fn ColorSyncProfileSetTag(
                prof: &ColorSyncMutableProfile,
                signature: &CFString,
                data: &CFData,
            );
        }
        unsafe { ColorSyncProfileSetTag(self, signature, data) }
    }

    #[doc(alias = "ColorSyncProfileRemoveTag")]
    #[inline]
    pub unsafe fn remove_tag(&self, signature: &CFString) {
        extern "C-unwind" {
            fn ColorSyncProfileRemoveTag(prof: &ColorSyncMutableProfile, signature: &CFString);
        }
        unsafe { ColorSyncProfileRemoveTag(self, signature) }
    }
}

/// [Apple's documentation](https://developer.apple.com/documentation/colorsync/colorsyncprofileiteratecallback?language=objc)
pub type ColorSyncProfileIterateCallback =
    Option<unsafe extern "C-unwind" fn(NonNull<CFDictionary>, NonNull<c_void>) -> bool>;

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncprofilecacheseed?language=objc)
    pub static kColorSyncProfileCacheSeed: &'static CFString;
}

extern "C-unwind" {
    /// # Safety
    ///
    /// - `call_back` must be implemented correctly.
    /// - `seed` must be a valid pointer or null.
    /// - `user_info` must be a valid pointer or null.
    /// - `error` must be a valid pointer or null.
    pub fn ColorSyncIterateInstalledProfiles(
        call_back: ColorSyncProfileIterateCallback,
        seed: *mut u32,
        user_info: *mut c_void,
        error: *mut *mut CFError,
    );
}

extern "C" {
    /// [Apple's documentation](https://developer.apple.com/documentation/colorsync/kcolorsyncwaitforcachereply?language=objc)
    pub static kColorSyncWaitForCacheReply: &'static CFString;
}

extern "C-unwind" {
    /// # Safety
    ///
    /// - `call_back` must be implemented correctly.
    /// - `seed` must be a valid pointer or null.
    /// - `user_info` must be a valid pointer or null.
    /// - `options` generics must be of the correct type.
    /// - `error` must be a valid pointer or null.
    pub fn ColorSyncIterateInstalledProfilesWithOptions(
        call_back: ColorSyncProfileIterateCallback,
        seed: *mut u32,
        user_info: *mut c_void,
        options: Option<&CFDictionary>,
        error: *mut *mut CFError,
    );
}

impl ColorSyncProfile {
    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileInstall")]
    #[inline]
    pub unsafe fn install(
        &self,
        domain: &CFString,
        subpath: &CFString,
        error: *mut *mut CFError,
    ) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileInstall(
                profile: &ColorSyncProfile,
                domain: &CFString,
                subpath: &CFString,
                error: *mut *mut CFError,
            ) -> bool;
        }
        unsafe { ColorSyncProfileInstall(self, domain, subpath, error) }
    }

    /// # Safety
    ///
    /// `error` must be a valid pointer or null.
    #[doc(alias = "ColorSyncProfileUninstall")]
    #[inline]
    pub unsafe fn uninstall(&self, error: *mut *mut CFError) -> bool {
        extern "C-unwind" {
            fn ColorSyncProfileUninstall(
                profile: &ColorSyncProfile,
                error: *mut *mut CFError,
            ) -> bool;
        }
        unsafe { ColorSyncProfileUninstall(self, error) }
    }
}

#[deprecated = "renamed to `ColorSyncProfile::new`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreate(
    data: &CFData,
    error: *mut *mut CFError,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreate(
            data: &CFData,
            error: *mut *mut CFError,
        ) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreate(data, error) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::with_url`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateWithURL(
    url: &CFURL,
    error: *mut *mut CFError,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateWithURL(
            url: &CFURL,
            error: *mut *mut CFError,
        ) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateWithURL(url, error) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::with_name`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateWithName(
    name: &CFString,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateWithName(name: &CFString) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateWithName(name) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::with_display_id`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateWithDisplayID(
    display_id: u32,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateWithDisplayID(
            display_id: u32,
        ) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateWithDisplayID(display_id) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::new_device_profile`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateDeviceProfile(
    device_class: &CFString,
    device_id: &CFUUID,
    profile_id: &CFType,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateDeviceProfile(
            device_class: &CFString,
            device_id: &CFUUID,
            profile_id: &CFType,
        ) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateDeviceProfile(device_class, device_id, profile_id) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncMutableProfile::new`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateMutable(
) -> Option<CFRetained<ColorSyncMutableProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateMutable() -> Option<NonNull<ColorSyncMutableProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateMutable() };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncMutableProfile::new_copy`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateMutableCopy(
    prof: &ColorSyncProfile,
) -> Option<CFRetained<ColorSyncMutableProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateMutableCopy(
            prof: &ColorSyncProfile,
        ) -> Option<NonNull<ColorSyncMutableProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateMutableCopy(prof) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::new_link`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateLink(
    profile_info: &CFArray,
    options: Option<&CFDictionary>,
) -> Option<CFRetained<ColorSyncProfile>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateLink(
            profile_info: &CFArray,
            options: Option<&CFDictionary>,
        ) -> Option<NonNull<ColorSyncProfile>>;
    }
    let ret = unsafe { ColorSyncProfileCreateLink(profile_info, options) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::verify`"]
    pub fn ColorSyncProfileVerify(
        prof: &ColorSyncProfile,
        errors: *mut *mut CFError,
        warnings: *mut *mut CFError,
    ) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::is_wide_gamut`"]
    pub fn ColorSyncProfileIsWideGamut(param1: &ColorSyncProfile) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::is_matrix_based`"]
    pub fn ColorSyncProfileIsMatrixBased(param1: &ColorSyncProfile) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::is_pq_based`"]
    pub fn ColorSyncProfileIsPQBased(param1: &ColorSyncProfile) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::is_hlg_based`"]
    pub fn ColorSyncProfileIsHLGBased(param1: &ColorSyncProfile) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::estimate_gamma_with_display_id`"]
    pub fn ColorSyncProfileEstimateGammaWithDisplayID(
        display_id: i32,
        error: *mut *mut CFError,
    ) -> c_float;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::estimate_gamma`"]
    pub fn ColorSyncProfileEstimateGamma(
        prof: &ColorSyncProfile,
        error: *mut *mut CFError,
    ) -> c_float;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::display_transfer_formula_from_vcgt`"]
    pub fn ColorSyncProfileGetDisplayTransferFormulaFromVCGT(
        profile: &ColorSyncProfile,
        red_min: NonNull<c_float>,
        red_max: NonNull<c_float>,
        red_gamma: NonNull<c_float>,
        green_min: NonNull<c_float>,
        green_max: NonNull<c_float>,
        green_gamma: NonNull<c_float>,
        blue_min: NonNull<c_float>,
        blue_max: NonNull<c_float>,
        blue_gamma: NonNull<c_float>,
    ) -> bool;
}

#[deprecated = "renamed to `ColorSyncProfile::display_transfer_tables_from_vcgt`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCreateDisplayTransferTablesFromVCGT(
    profile: &ColorSyncProfile,
    n_samples_per_channel: NonNull<usize>,
) -> Option<CFRetained<CFData>> {
    extern "C-unwind" {
        fn ColorSyncProfileCreateDisplayTransferTablesFromVCGT(
            profile: &ColorSyncProfile,
            n_samples_per_channel: NonNull<usize>,
        ) -> Option<NonNull<CFData>>;
    }
    let ret = unsafe {
        ColorSyncProfileCreateDisplayTransferTablesFromVCGT(profile, n_samples_per_channel)
    };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::md_5`"]
    pub fn ColorSyncProfileGetMD5(prof: &ColorSyncProfile) -> ColorSyncMD5;
}

#[deprecated = "renamed to `ColorSyncProfile::data`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCopyData(
    prof: &ColorSyncProfile,
    error: *mut *mut CFError,
) -> CFRetained<CFData> {
    extern "C-unwind" {
        fn ColorSyncProfileCopyData(
            prof: &ColorSyncProfile,
            error: *mut *mut CFError,
        ) -> Option<NonNull<CFData>>;
    }
    let ret = unsafe { ColorSyncProfileCopyData(prof, error) };
    let ret = ret.expect("function was marked as returning non-null, but actually returned NULL");
    unsafe { CFRetained::from_raw(ret) }
}

#[deprecated = "renamed to `ColorSyncProfile::url`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileGetURL(
    prof: &ColorSyncProfile,
    error: *mut *mut CFError,
) -> CFRetained<CFURL> {
    extern "C-unwind" {
        fn ColorSyncProfileGetURL(
            prof: &ColorSyncProfile,
            error: *mut *mut CFError,
        ) -> Option<NonNull<CFURL>>;
    }
    let ret = unsafe { ColorSyncProfileGetURL(prof, error) };
    let ret = ret.expect("function was marked as returning non-null, but actually returned NULL");
    unsafe { CFRetained::retain(ret) }
}

#[deprecated = "renamed to `ColorSyncProfile::header`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCopyHeader(
    prof: &ColorSyncProfile,
) -> CFRetained<CFData> {
    extern "C-unwind" {
        fn ColorSyncProfileCopyHeader(prof: &ColorSyncProfile) -> Option<NonNull<CFData>>;
    }
    let ret = unsafe { ColorSyncProfileCopyHeader(prof) };
    let ret = ret.expect("function was marked as returning non-null, but actually returned NULL");
    unsafe { CFRetained::from_raw(ret) }
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncMutableProfile::set_header`"]
    pub fn ColorSyncProfileSetHeader(prof: &ColorSyncMutableProfile, header: &CFData);
}

#[deprecated = "renamed to `ColorSyncProfile::description_string`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCopyDescriptionString(
    prof: &ColorSyncProfile,
) -> Option<CFRetained<CFString>> {
    extern "C-unwind" {
        fn ColorSyncProfileCopyDescriptionString(
            prof: &ColorSyncProfile,
        ) -> Option<NonNull<CFString>>;
    }
    let ret = unsafe { ColorSyncProfileCopyDescriptionString(prof) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

#[deprecated = "renamed to `ColorSyncProfile::tag_signatures`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCopyTagSignatures(
    prof: &ColorSyncProfile,
) -> Option<CFRetained<CFArray>> {
    extern "C-unwind" {
        fn ColorSyncProfileCopyTagSignatures(prof: &ColorSyncProfile) -> Option<NonNull<CFArray>>;
    }
    let ret = unsafe { ColorSyncProfileCopyTagSignatures(prof) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::contains_tag`"]
    pub fn ColorSyncProfileContainsTag(prof: &ColorSyncProfile, signature: &CFString) -> bool;
}

#[deprecated = "renamed to `ColorSyncProfile::tag`"]
#[inline]
pub unsafe extern "C-unwind" fn ColorSyncProfileCopyTag(
    prof: &ColorSyncProfile,
    signature: &CFString,
) -> Option<CFRetained<CFData>> {
    extern "C-unwind" {
        fn ColorSyncProfileCopyTag(
            prof: &ColorSyncProfile,
            signature: &CFString,
        ) -> Option<NonNull<CFData>>;
    }
    let ret = unsafe { ColorSyncProfileCopyTag(prof, signature) };
    ret.map(|ret| unsafe { CFRetained::from_raw(ret) })
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncMutableProfile::set_tag`"]
    pub fn ColorSyncProfileSetTag(
        prof: &ColorSyncMutableProfile,
        signature: &CFString,
        data: &CFData,
    );
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncMutableProfile::remove_tag`"]
    pub fn ColorSyncProfileRemoveTag(prof: &ColorSyncMutableProfile, signature: &CFString);
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::install`"]
    pub fn ColorSyncProfileInstall(
        profile: &ColorSyncProfile,
        domain: &CFString,
        subpath: &CFString,
        error: *mut *mut CFError,
    ) -> bool;
}

extern "C-unwind" {
    #[deprecated = "renamed to `ColorSyncProfile::uninstall`"]
    pub fn ColorSyncProfileUninstall(profile: &ColorSyncProfile, error: *mut *mut CFError) -> bool;
}
