pub struct Pasteboard { /* private fields */ }Available on crate feature
Pasteboard only.Expand description
Implementations§
Source§impl Pasteboard
impl Pasteboard
Sourcepub unsafe fn create(
in_name: Option<&CFString>,
out_pasteboard: NonNull<*mut Pasteboard>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn create( in_name: Option<&CFString>, out_pasteboard: NonNull<*mut Pasteboard>, ) -> u32
HIServices only.§Safety
out_pasteboard must be a valid pointer.
pub unsafe fn synchronize(&self) -> PasteboardSyncFlags
Available on crate feature
HIServices only.pub unsafe fn clear(&self) -> u32
Available on crate feature
HIServices only.Sourcepub unsafe fn copy_name(&self, out_name: NonNull<*const CFString>) -> u32
Available on crate feature HIServices only.
pub unsafe fn copy_name(&self, out_name: NonNull<*const CFString>) -> u32
HIServices only.§Safety
out_name must be a valid pointer.
Sourcepub unsafe fn item_count(&self, out_item_count: NonNull<c_ulong>) -> u32
Available on crate feature HIServices only.
pub unsafe fn item_count(&self, out_item_count: NonNull<c_ulong>) -> u32
HIServices only.§Safety
out_item_count must be a valid pointer.
Sourcepub unsafe fn item_identifier(
&self,
in_index: CFIndex,
out_item: NonNull<PasteboardItemID>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn item_identifier( &self, in_index: CFIndex, out_item: NonNull<PasteboardItemID>, ) -> u32
HIServices only.§Safety
out_item must be a valid pointer.
Sourcepub unsafe fn copy_item_flavors(
&self,
in_item: PasteboardItemID,
out_flavor_types: NonNull<*const CFArray>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn copy_item_flavors( &self, in_item: PasteboardItemID, out_flavor_types: NonNull<*const CFArray>, ) -> u32
HIServices only.§Safety
in_itemmust be a valid pointer.out_flavor_typesmust be a valid pointer.
Sourcepub unsafe fn item_flavor_flags(
&self,
in_item: PasteboardItemID,
in_flavor_type: &CFString,
out_flags: NonNull<PasteboardFlavorFlags>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn item_flavor_flags( &self, in_item: PasteboardItemID, in_flavor_type: &CFString, out_flags: NonNull<PasteboardFlavorFlags>, ) -> u32
HIServices only.§Safety
in_itemmust be a valid pointer.out_flagsmust be a valid pointer.
Sourcepub unsafe fn copy_item_flavor_data(
&self,
in_item: PasteboardItemID,
in_flavor_type: &CFString,
out_data: NonNull<*const CFData>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn copy_item_flavor_data( &self, in_item: PasteboardItemID, in_flavor_type: &CFString, out_data: NonNull<*const CFData>, ) -> u32
HIServices only.§Safety
in_itemmust be a valid pointer.out_datamust be a valid pointer.
Sourcepub unsafe fn put_item_flavor(
&self,
in_item: PasteboardItemID,
in_flavor_type: &CFString,
in_data: Option<&CFData>,
in_flags: PasteboardFlavorFlags,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn put_item_flavor( &self, in_item: PasteboardItemID, in_flavor_type: &CFString, in_data: Option<&CFData>, in_flags: PasteboardFlavorFlags, ) -> u32
HIServices only.§Safety
in_item must be a valid pointer.
Sourcepub unsafe fn copy_paste_location(
&self,
out_paste_location: NonNull<*const CFURL>,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn copy_paste_location( &self, out_paste_location: NonNull<*const CFURL>, ) -> u32
HIServices only.§Safety
out_paste_location must be a valid pointer.
pub unsafe fn set_paste_location(&self, in_paste_location: &CFURL) -> u32
Available on crate feature
HIServices only.Source§impl Pasteboard
impl Pasteboard
Sourcepub unsafe fn set_promise_keeper(
&self,
in_promise_keeper: PasteboardPromiseKeeperProcPtr,
in_context: *mut c_void,
) -> u32
Available on crate feature HIServices only.
pub unsafe fn set_promise_keeper( &self, in_promise_keeper: PasteboardPromiseKeeperProcPtr, in_context: *mut c_void, ) -> u32
HIServices only.§Safety
in_promise_keepermust be implemented correctly.in_contextmust be a valid pointer or null.
pub unsafe fn resolve_promises(&self) -> u32
Available on crate feature
HIServices only.Methods from Deref<Target = CFType>§
Sourcepub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
pub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
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
pub fn retain_count(&self) -> usize
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 Pasteboard
Available on crate feature HIServices only.
impl AsRef<AnyObject> for Pasteboard
Available on crate feature
HIServices only.Source§impl AsRef<CFType> for Pasteboard
Available on crate feature HIServices only.
impl AsRef<CFType> for Pasteboard
Available on crate feature
HIServices only.Source§impl AsRef<Pasteboard> for Pasteboard
Available on crate feature HIServices only.
impl AsRef<Pasteboard> for Pasteboard
Available on crate feature
HIServices only.Source§impl Borrow<AnyObject> for Pasteboard
Available on crate feature HIServices only.
impl Borrow<AnyObject> for Pasteboard
Available on crate feature
HIServices only.Source§impl Borrow<CFType> for Pasteboard
Available on crate feature HIServices only.
impl Borrow<CFType> for Pasteboard
Available on crate feature
HIServices only.Source§impl ConcreteType for Pasteboard
Available on crate feature HIServices only.
impl ConcreteType for Pasteboard
Available on crate feature
HIServices only.Source§impl Debug for Pasteboard
Available on crate feature HIServices only.
impl Debug for Pasteboard
Available on crate feature
HIServices only.Source§impl Deref for Pasteboard
Available on crate feature HIServices only.
impl Deref for Pasteboard
Available on crate feature
HIServices only.Source§impl Hash for Pasteboard
Available on crate feature HIServices only.
impl Hash for Pasteboard
Available on crate feature
HIServices only.Source§impl Message for Pasteboard
Available on crate feature HIServices only.
impl Message for Pasteboard
Available on crate feature
HIServices only.Source§impl PartialEq for Pasteboard
Available on crate feature HIServices only.
impl PartialEq for Pasteboard
Available on crate feature
HIServices only.Source§impl RefEncode for Pasteboard
Available on crate feature HIServices only.
impl RefEncode for Pasteboard
Available on crate feature
HIServices only.Source§const ENCODING_REF: Encoding
const ENCODING_REF: Encoding
The Objective-C type-encoding for a reference of this type. Read more
Source§impl Type for Pasteboard
Available on crate feature HIServices only.
impl Type for Pasteboard
Available on crate feature
HIServices only.Source§fn retain(&self) -> CFRetained<Self>where
Self: Sized,
fn retain(&self) -> CFRetained<Self>where
Self: Sized,
Increment the reference count of the receiver. Read more
Source§fn as_concrete_TypeRef(&self) -> &Self
fn as_concrete_TypeRef(&self) -> &Self
👎Deprecated: this is redundant
Helper for easier transition from the
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,
👎Deprecated: use CFRetained::retain
Helper for easier transition from the
core-foundation crate. Read moreSource§fn as_CFTypeRef(&self) -> &CFType
fn as_CFTypeRef(&self) -> &CFType
👎Deprecated: this is redundant (CF types deref to CFType)
Helper for easier transition from the
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,
👎Deprecated: use CFRetained::from_raw
Helper for easier transition from the
core-foundation crate. Read moreimpl Eq for Pasteboard
Available on crate feature
HIServices only.Auto Trait Implementations§
impl !Freeze for Pasteboard
impl !RefUnwindSafe for Pasteboard
impl !Send for Pasteboard
impl !Sync for Pasteboard
impl !Unpin for Pasteboard
impl !UnwindSafe for Pasteboard
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more