pub struct SeqPacketListener { /* private fields */ }
Available on crate feature l2cap only.
Expand description

An L2CAP socket server, listening for SeqPacket connections.

Implementations

Creates a new Listener, which will be bound to the specified socket address.

Specify SocketAddr::any_br_edr or SocketAddr::any_le for any local adapter address with a dynamically allocated PSM.

Accepts a new incoming connection from this listener.

Polls to accept a new incoming connection to this listener.

Constructs a new SeqPacketListener from the given raw file descriptor.

The file descriptor must have been set to non-blocking mode.

This function consumes ownership of the specified file descriptor. The returned object will take responsibility for closing it when the object goes out of scope.

Safety

If the passed file descriptor is invalid, undefined behavior may occur.

Trait Implementations

Extracts the raw file descriptor. Read more
Converts this type into a shared reference of the (usually inferred) input type.
Formats the value using the given formatter. Read more

Constructs a new instance of Self from the given raw file descriptor.

The file descriptor must have been set to non-blocking mode.

Panics

Panics when the conversion fails. Use SeqPacketListener::from_raw_fd for a non-panicking variant.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.