pub struct BoundAllocation { /* private fields */ }Expand description
Non-RAII allocation metadata issued by one MemoryBinding.
Dropping this value does not free memory. Call MemoryBinding::release
explicitly through the same binding.
Implementations§
Source§impl BoundAllocation
impl BoundAllocation
pub const fn identity(&self) -> AllocationIdentity
pub const fn binding(&self) -> &MemoryBinding
pub const fn as_ptr(&self) -> NonNull<u8>
pub const fn len(&self) -> usize
pub const fn is_empty(&self) -> bool
pub const fn alignment(&self) -> usize
pub fn view( &self, offset: usize, bytes: usize, ) -> Result<BoundMemoryView, BindingError>
Trait Implementations§
Source§impl Debug for BoundAllocation
impl Debug for BoundAllocation
impl Send for BoundAllocation
impl Sync for BoundAllocation
Auto Trait Implementations§
impl !RefUnwindSafe for BoundAllocation
impl !UnwindSafe for BoundAllocation
impl Freeze for BoundAllocation
impl Unpin for BoundAllocation
impl UnsafeUnpin for BoundAllocation
Blanket Implementations§
impl<T> BindingResource for T
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