[−][src]Struct rubble::link::Responder
Data channel packet processor.
This hooks up to the Real-Time part of the LE Link Layer via a packet queue. This part can run at a lower priority (eg. being driven in the apps idle loop) and receives and transmits packets using the packet queue.
Some LL Control PDUs sent as part of the Link Layer Control Protocol (LLCP) are answered by
the responder directly, and all L2CAP data is forwarded to an L2CAPState<M>
. Note that most
LLCPDUs are handled directly by the real-time code.
Methods
impl<M: ChannelMapper> Responder<M>
[src]
pub fn new(tx: Producer, rx: Consumer, l2cap: L2CAPState<M>) -> Self
[src]
pub fn has_work(&mut self) -> bool
[src]
Returns true
when this responder has work to do.
If this returns true
, process
may be called to process incoming packets and send
outgoing ones.
pub fn process_one(&mut self) -> Result<(), Error>
[src]
Processes a single incoming packet in the packet queue.
Returns Error::Eof
if there are no incoming packets in the RX queue.
Auto Trait Implementations
Blanket Implementations
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> From for T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,