pub struct LibraryFunctionDescriptor(/* private fields */);Expand description
Descriptor for a function from a library.
C++ equivalent: MTL4::LibraryFunctionDescriptor
LibraryFunctionDescriptor extends FunctionDescriptor to reference a specific function from a Metal library by name.
Implementations§
Source§impl LibraryFunctionDescriptor
impl LibraryFunctionDescriptor
Sourcepub unsafe fn from_raw(ptr: *mut c_void) -> Option<Self>
pub unsafe fn from_raw(ptr: *mut c_void) -> Option<Self>
Create a LibraryFunctionDescriptor from a raw pointer.
Sourcepub fn library(&self) -> Option<Library>
pub fn library(&self) -> Option<Library>
Get the library.
C++ equivalent: MTL::Library* library() const
Sourcepub fn set_library(&self, library: &Library)
pub fn set_library(&self, library: &Library)
Set the library.
C++ equivalent: void setLibrary(const MTL::Library*)
Trait Implementations§
Source§impl Clone for LibraryFunctionDescriptor
impl Clone for LibraryFunctionDescriptor
Source§impl Debug for LibraryFunctionDescriptor
impl Debug for LibraryFunctionDescriptor
Source§impl Default for LibraryFunctionDescriptor
impl Default for LibraryFunctionDescriptor
Source§impl Drop for LibraryFunctionDescriptor
impl Drop for LibraryFunctionDescriptor
Source§impl Referencing for LibraryFunctionDescriptor
impl Referencing for LibraryFunctionDescriptor
Source§fn as_mut_ptr(&self) -> *mut c_void
fn as_mut_ptr(&self) -> *mut c_void
Get the raw mutable pointer to the Objective-C object.
Source§fn retain(&self) -> Selfwhere
Self: Clone,
fn retain(&self) -> Selfwhere
Self: Clone,
Retain the object, incrementing its reference count. Read more
Source§fn autorelease(&self) -> Selfwhere
Self: Clone,
fn autorelease(&self) -> Selfwhere
Self: Clone,
Autorelease the object. Read more
Source§fn retain_count(&self) -> usize
fn retain_count(&self) -> usize
Get the retain count of the object. Read more
impl Send for LibraryFunctionDescriptor
impl Sync for LibraryFunctionDescriptor
Auto Trait Implementations§
impl Freeze for LibraryFunctionDescriptor
impl RefUnwindSafe for LibraryFunctionDescriptor
impl Unpin for LibraryFunctionDescriptor
impl UnwindSafe for LibraryFunctionDescriptor
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