objc2_security/generated/
SecProtocolObject.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::cell::UnsafeCell;
4use core::ffi::*;
5use core::marker::{PhantomData, PhantomPinned};
6#[cfg(feature = "objc2")]
7use objc2::__framework_prelude::*;
8
9use crate::*;
10
11extern "C-unwind" {
12    pub fn sec_retain(obj: *mut c_void) -> *mut c_void;
13}
14
15extern "C-unwind" {
16    pub fn sec_release(obj: *mut c_void);
17}
18
19/// A `sec_object` is a generic, ARC-able type wrapper for common CoreFoundation Security types.
20///
21/// See also [Apple's documentation](https://developer.apple.com/documentation/security/sec_object?language=objc)
22#[repr(C)]
23#[derive(Debug)]
24pub struct sec_object {
25    inner: [u8; 0],
26    _p: UnsafeCell<PhantomData<(*const UnsafeCell<()>, PhantomPinned)>>,
27}
28
29#[cfg(feature = "objc2")]
30unsafe impl RefEncode for sec_object {
31    const ENCODING_REF: Encoding = Encoding::Pointer(&Encoding::Struct("sec_object", &[]));
32}
33
34/// A `sec_object` is a generic, ARC-able type wrapper for common CoreFoundation Security types.
35///
36/// See also [Apple's documentation](https://developer.apple.com/documentation/security/sec_object_t?language=objc)
37pub type sec_object_t = *mut sec_object;