pub struct L2capChan(/* private fields */);Expand description
An opaque handle to an open L2CAP channel (wraps *mut ble_l2cap_chan).
§Validity
A handle is valid only while its channel is open — from L2capEvent::Connected /
L2capEvent::Accept until the matching L2capEvent::Disconnected. Using it afterwards is
undefined behavior (it dereferences freed NimBLE state). It is Send/Sync so it can be stashed
and used from another task (NimBLE serializes internally with its own lock) — which is exactly
why honoring the “not after Disconnected” rule is the caller’s responsibility.
Trait Implementations§
impl Copy for L2capChan
impl Send for L2capChan
impl Sync for L2capChan
Auto Trait Implementations§
impl Freeze for L2capChan
impl RefUnwindSafe for L2capChan
impl Unpin for L2capChan
impl UnsafeUnpin for L2capChan
impl UnwindSafe for L2capChan
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)