pub struct CSIdentity { /* private fields */ }CSIdentity only.Expand description
Implementations§
Source§impl CSIdentity
impl CSIdentity
Sourcepub unsafe fn new(
allocator: Option<&CFAllocator>,
identity_class: CSIdentityClass,
full_name: Option<&CFString>,
posix_name: Option<&CFString>,
flags: CSIdentityFlags,
authority: Option<&CSIdentityAuthority>,
) -> Option<CFRetained<CSIdentity>>
Available on crate features OSServices and CSIdentityAuthority only.
pub unsafe fn new( allocator: Option<&CFAllocator>, identity_class: CSIdentityClass, full_name: Option<&CFString>, posix_name: Option<&CFString>, flags: CSIdentityFlags, authority: Option<&CSIdentityAuthority>, ) -> Option<CFRetained<CSIdentity>>
OSServices and CSIdentityAuthority only.§Safety
allocatormight not allowNone.full_namemight not allowNone.posix_namemight not allowNone.authoritymight not allowNone.
Sourcepub unsafe fn new_copy(
allocator: Option<&CFAllocator>,
identity: Option<&CSIdentity>,
) -> Option<CFRetained<CSIdentity>>
Available on crate feature OSServices only.
pub unsafe fn new_copy( allocator: Option<&CFAllocator>, identity: Option<&CSIdentity>, ) -> Option<CFRetained<CSIdentity>>
OSServices only.§Safety
allocatormight not allowNone.identitymight not allowNone.
pub unsafe fn class(&self) -> CSIdentityClass
OSServices only.OSServices and CSIdentityAuthority only.pub unsafe fn uuid(&self) -> Option<CFRetained<CFUUID>>
OSServices only.pub unsafe fn full_name(&self) -> Option<CFRetained<CFString>>
OSServices only.pub unsafe fn posix_id(&self) -> id_t
OSServices and libc only.pub unsafe fn posix_name(&self) -> Option<CFRetained<CFString>>
OSServices only.pub unsafe fn email_address(&self) -> Option<CFRetained<CFString>>
OSServices only.pub unsafe fn image_url(&self) -> Option<CFRetained<CFURL>>
OSServices only.pub unsafe fn image_data(&self) -> Option<CFRetained<CFData>>
OSServices only.pub unsafe fn image_data_type(&self) -> Option<CFRetained<CFString>>
OSServices only.pub unsafe fn aliases(&self) -> Option<CFRetained<CFArray>>
OSServices only.Sourcepub unsafe fn is_member_of_group(&self, group: Option<&CSIdentity>) -> bool
Available on crate feature OSServices only.
pub unsafe fn is_member_of_group(&self, group: Option<&CSIdentity>) -> bool
OSServices only.§Safety
group might not allow None.
OSServices only.Sourcepub unsafe fn new_persistent_reference(
allocator: Option<&CFAllocator>,
identity: Option<&CSIdentity>,
) -> Option<CFRetained<CFData>>
Available on crate feature OSServices only.
pub unsafe fn new_persistent_reference( allocator: Option<&CFAllocator>, identity: Option<&CSIdentity>, ) -> Option<CFRetained<CFData>>
OSServices only.§Safety
allocatormight not allowNone.identitymight not allowNone.
pub unsafe fn is_enabled(&self) -> bool
OSServices only.Sourcepub unsafe fn authenticate_using_password(
&self,
password: Option<&CFString>,
) -> bool
Available on crate feature OSServices only.
pub unsafe fn authenticate_using_password( &self, password: Option<&CFString>, ) -> bool
OSServices only.§Safety
password might not allow None.
pub unsafe fn certificate(&self) -> Option<CFRetained<SecCertificate>>
OSServices and objc2-security only.Sourcepub unsafe fn new_group_membership_query(
allocator: Option<&CFAllocator>,
group: Option<&CSIdentity>,
) -> Option<CFRetained<CSIdentityQuery>>
Available on crate feature OSServices only.
pub unsafe fn new_group_membership_query( allocator: Option<&CFAllocator>, group: Option<&CSIdentity>, ) -> Option<CFRetained<CSIdentityQuery>>
OSServices only.§Safety
allocatormight not allowNone.groupmight not allowNone.
Sourcepub unsafe fn set_full_name(&self, full_name: Option<&CFString>)
Available on crate feature OSServices only.
pub unsafe fn set_full_name(&self, full_name: Option<&CFString>)
OSServices only.§Safety
full_name might not allow None.
Sourcepub unsafe fn set_email_address(&self, email_address: Option<&CFString>)
Available on crate feature OSServices only.
pub unsafe fn set_email_address(&self, email_address: Option<&CFString>)
OSServices only.§Safety
email_address might not allow None.
Sourcepub unsafe fn set_image_url(&self, url: Option<&CFURL>)
Available on crate feature OSServices only.
pub unsafe fn set_image_url(&self, url: Option<&CFURL>)
OSServices only.§Safety
url might not allow None.
Sourcepub unsafe fn set_image_data(
&self,
image_data: Option<&CFData>,
image_data_type: Option<&CFString>,
)
Available on crate feature OSServices only.
pub unsafe fn set_image_data( &self, image_data: Option<&CFData>, image_data_type: Option<&CFString>, )
OSServices only.§Safety
image_datamight not allowNone.image_data_typemight not allowNone.
Sourcepub unsafe fn add_alias(&self, alias: Option<&CFString>)
Available on crate feature OSServices only.
pub unsafe fn add_alias(&self, alias: Option<&CFString>)
OSServices only.§Safety
alias might not allow None.
Sourcepub unsafe fn remove_alias(&self, alias: Option<&CFString>)
Available on crate feature OSServices only.
pub unsafe fn remove_alias(&self, alias: Option<&CFString>)
OSServices only.§Safety
alias might not allow None.
Sourcepub unsafe fn add_member(&self, member: Option<&CSIdentity>)
Available on crate feature OSServices only.
pub unsafe fn add_member(&self, member: Option<&CSIdentity>)
OSServices only.§Safety
member might not allow None.
Sourcepub unsafe fn remove_member(&self, member: Option<&CSIdentity>)
Available on crate feature OSServices only.
pub unsafe fn remove_member(&self, member: Option<&CSIdentity>)
OSServices only.§Safety
member might not allow None.
pub unsafe fn set_is_enabled(&self, is_enabled: bool)
OSServices only.Sourcepub unsafe fn set_password(&self, password: Option<&CFString>)
Available on crate feature OSServices only.
pub unsafe fn set_password(&self, password: Option<&CFString>)
OSServices only.§Safety
password might not allow None.
Sourcepub unsafe fn set_certificate(&self, certificate: Option<&SecCertificate>)
Available on crate features OSServices and objc2-security only.
pub unsafe fn set_certificate(&self, certificate: Option<&SecCertificate>)
OSServices and objc2-security only.§Safety
certificate might not allow None.
pub unsafe fn delete(&self)
OSServices only.Source§impl CSIdentity
impl CSIdentity
Sourcepub unsafe fn commit_asynchronously(
&self,
client_context: *const CSIdentityClientContext,
run_loop: Option<&CFRunLoop>,
run_loop_mode: Option<&CFString>,
authorization: AuthorizationRef,
) -> bool
Available on crate features OSServices and objc2-security only.
pub unsafe fn commit_asynchronously( &self, client_context: *const CSIdentityClientContext, run_loop: Option<&CFRunLoop>, run_loop_mode: Option<&CFString>, authorization: AuthorizationRef, ) -> bool
OSServices and objc2-security only.§Safety
client_contextmust be a valid pointer.run_looppossibly has additional threading requirements.run_loopmight not allowNone.run_loop_modemight not allowNone.authorizationmust be a valid pointer.
pub unsafe fn is_committing(&self) -> bool
OSServices only.pub unsafe fn remove_client(&self)
OSServices only.Methods from Deref<Target = CFType>§
Sourcepub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
Available on crate features SearchKit and SKDocument only.
pub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
SearchKit and SKDocument only.Attempt to downcast the type to that of type T.
This is the reference-variant. Use CFRetained::downcast if you
want to convert a retained type. See also ConcreteType for more
details on which types support being converted to.
Sourcepub fn retain_count(&self) -> usize
Available on crate features SearchKit and SKDocument only.
pub fn retain_count(&self) -> usize
SearchKit and SKDocument only.Get the reference count of the object.
This function may be useful for debugging. You normally do not use this function otherwise.
Beware that some things (like CFNumbers, small CFStrings etc.) may
not have a normal retain count for optimization purposes, and can
return usize::MAX in that case.
Trait Implementations§
Source§impl AsRef<AnyObject> for CSIdentity
Available on crate feature OSServices only.
impl AsRef<AnyObject> for CSIdentity
OSServices only.Source§impl AsRef<CFType> for CSIdentity
Available on crate feature OSServices only.
impl AsRef<CFType> for CSIdentity
OSServices only.Source§impl AsRef<CSIdentity> for CSIdentity
Available on crate feature OSServices only.
impl AsRef<CSIdentity> for CSIdentity
OSServices only.Source§impl Borrow<AnyObject> for CSIdentity
Available on crate feature OSServices only.
impl Borrow<AnyObject> for CSIdentity
OSServices only.Source§impl Borrow<CFType> for CSIdentity
Available on crate feature OSServices only.
impl Borrow<CFType> for CSIdentity
OSServices only.Source§impl ConcreteType for CSIdentity
Available on crate feature OSServices only.
impl ConcreteType for CSIdentity
OSServices only.Source§impl Debug for CSIdentity
Available on crate feature OSServices only.
impl Debug for CSIdentity
OSServices only.Source§impl Deref for CSIdentity
Available on crate feature OSServices only.
impl Deref for CSIdentity
OSServices only.Source§impl Hash for CSIdentity
Available on crate feature OSServices only.
impl Hash for CSIdentity
OSServices only.Source§impl Message for CSIdentity
Available on crate feature OSServices only.
impl Message for CSIdentity
OSServices only.Source§impl PartialEq for CSIdentity
Available on crate feature OSServices only.
impl PartialEq for CSIdentity
OSServices only.Source§impl RefEncode for CSIdentity
Available on crate feature OSServices only.
impl RefEncode for CSIdentity
OSServices only.Source§const ENCODING_REF: Encoding
const ENCODING_REF: Encoding
Source§impl Type for CSIdentity
Available on crate feature OSServices only.
impl Type for CSIdentity
OSServices only.Source§fn retain(&self) -> CFRetained<Self>where
Self: Sized,
fn retain(&self) -> CFRetained<Self>where
Self: Sized,
Source§fn as_concrete_TypeRef(&self) -> &Self
fn as_concrete_TypeRef(&self) -> &Self
core-foundation crate.Source§unsafe fn wrap_under_get_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
unsafe fn wrap_under_get_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
core-foundation crate. Read moreSource§fn as_CFTypeRef(&self) -> &CFType
fn as_CFTypeRef(&self) -> &CFType
core-foundation crate.Source§unsafe fn wrap_under_create_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
unsafe fn wrap_under_create_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
core-foundation crate. Read moreimpl Eq for CSIdentity
OSServices only.