[−][src]Struct ssdp::SSDPReceiver
A non-blocking SSDP message receiver.
Methods
impl<T> SSDPReceiver<T> where
T: FromRawSSDP + Send + 'static,
[src]
impl<T> SSDPReceiver<T> where
T: FromRawSSDP + Send + 'static,
pub fn new(
socks: Vec<UdpSocket>,
time: Option<Duration>
) -> Result<SSDPReceiver<T>>
[src]
pub fn new(
socks: Vec<UdpSocket>,
time: Option<Duration>
) -> Result<SSDPReceiver<T>>
Construct a receiver that receives bytes from a number of UdpSockets and tries to construct an object T from them. If a duration is provided, the channel will be shutdown after the specified duration.
Due to implementation details, none of the UdpSockets should be bound to the default route, 0.0.0.0, address.
impl<T> SSDPReceiver<T>
[src]
impl<T> SSDPReceiver<T>
pub fn try_recv(&self) -> Result<(T, SocketAddr), TryRecvError>
[src]
pub fn try_recv(&self) -> Result<(T, SocketAddr), TryRecvError>
Non-blocking method that attempts to read a value from the receiver.
pub fn recv(&self) -> Result<(T, SocketAddr), RecvError>
[src]
pub fn recv(&self) -> Result<(T, SocketAddr), RecvError>
Blocking method that reads a value from the receiver until one is available.
Trait Implementations
impl<'a, T> IntoIterator for &'a SSDPReceiver<T>
[src]
impl<'a, T> IntoIterator for &'a SSDPReceiver<T>
type Item = (T, SocketAddr)
The type of the elements being iterated over.
type IntoIter = Iter<'a, (T, SocketAddr)>
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
[src]
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl<'a, T> IntoIterator for &'a mut SSDPReceiver<T>
[src]
impl<'a, T> IntoIterator for &'a mut SSDPReceiver<T>
type Item = (T, SocketAddr)
The type of the elements being iterated over.
type IntoIter = Iter<'a, (T, SocketAddr)>
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
[src]
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl<T> IntoIterator for SSDPReceiver<T>
[src]
impl<T> IntoIterator for SSDPReceiver<T>
Auto Trait Implementations
impl<T> Send for SSDPReceiver<T> where
T: Send,
impl<T> Send for SSDPReceiver<T> where
T: Send,
impl<T> !Sync for SSDPReceiver<T>
impl<T> !Sync for SSDPReceiver<T>
Blanket Implementations
impl<T> From for T
[src]
impl<T> From for T
impl<I> IntoIterator for I where
I: Iterator,
[src]
impl<I> IntoIterator for I where
I: Iterator,
type Item = <I as Iterator>::Item
The type of the elements being iterated over.
type IntoIter = I
Which kind of iterator are we turning this into?
fn into_iter(self) -> I
[src]
fn into_iter(self) -> I
Creates an iterator from a value. Read more
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more
impl<T> Typeable for T where
T: Any,
[src]
impl<T> Typeable for T where
T: Any,