pub enum MetalBufferAccessError {
CpuInaccessibleStorage {
storage_mode: usize,
},
MappingUnavailable,
MappingLockPoisoned,
RangeOutOfBounds {
offset: usize,
length: usize,
buffer_length: usize,
},
InvalidRange,
ManagedStorageRequired {
storage_mode: usize,
},
}Expand description
Errors returned by CPU access to a MetalBuffer.
Variants§
CpuInaccessibleStorage
The buffer’s storage mode does not expose CPU-addressable bytes.
Metal did not provide a CPU mapping for an otherwise accessible buffer.
MappingLockPoisoned
Another mapping panicked while holding the allocation’s mapping lock.
RangeOutOfBounds
The requested byte range is outside the allocation.
InvalidRange
The supplied range has its end before its start.
ManagedStorageRequired
The operation requires managed storage.
Trait Implementations§
Source§impl Clone for MetalBufferAccessError
impl Clone for MetalBufferAccessError
Source§fn clone(&self) -> MetalBufferAccessError
fn clone(&self) -> MetalBufferAccessError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MetalBufferAccessError
impl Debug for MetalBufferAccessError
Source§impl Display for MetalBufferAccessError
impl Display for MetalBufferAccessError
impl Eq for MetalBufferAccessError
Source§impl Error for MetalBufferAccessError
impl Error for MetalBufferAccessError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for MetalBufferAccessError
impl PartialEq for MetalBufferAccessError
impl StructuralPartialEq for MetalBufferAccessError
Auto Trait Implementations§
impl Freeze for MetalBufferAccessError
impl RefUnwindSafe for MetalBufferAccessError
impl Send for MetalBufferAccessError
impl Sync for MetalBufferAccessError
impl Unpin for MetalBufferAccessError
impl UnsafeUnpin for MetalBufferAccessError
impl UnwindSafe for MetalBufferAccessError
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