A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://docs.rs/cap-net-ext/latest/cap_net_ext/struct.TcpConnecter.html below:

TcpConnecter in cap_net_ext - Rust

cap_net_ext Struct TcpConnecterSource
pub struct TcpConnecter(/* private fields */);
Expand description

A utility for making TCP connections.

See PoolExt::tcp_connecter for details.

Implementations§ Source§ impl TcpConnecter Source pub fn connect_into_tcp_stream(&self, socket: TcpListener) -> Result<TcpStream>

Initiate a TCP connection, converting a TcpListener to a TcpStream.

This is simlar to Pool::connect_tcp_stream in that it performs a TCP connection, but instead of creating a new socket itself it takes a TcpListener, such as one created with TcpListenerExt::new.

Despite the name, this function uses the TcpListener type as a generic socket container.

This is similar to PoolExt::connect_into_tcp_stream except that it uses a TcpConnecter which contains addresses that have already been checked against a Pool.

Source pub fn connect_existing_tcp_listener(&self, socket: &TcpListener) -> Result<()>

Initiate a TCP connection on a socket.

This is simlar to Pool::connect_into_tcp_stream, however instead of converting a TcpListener to a TcpStream, it leaves fd in the existing TcpListener.

This is similar to PoolExt::connect_existing_tcp_listener except that it uses a TcpConnecter which contains addresses that have already been checked against a Pool.

Auto Trait Implementations§ § impl Freeze for TcpConnecter § impl RefUnwindSafe for TcpConnecter § impl Send for TcpConnecter § impl Sync for TcpConnecter § impl Unpin for TcpConnecter § impl UnwindSafe for TcpConnecter Blanket Implementations§ Source§ impl<T> Any for T

where T: 'static + ?

Sized

,

Source§ fn type_id(&self) -> TypeId

Gets the

TypeId

of

self

.

Read more Source§ impl<T> Borrow<T> for T

where T: ?

Sized

,

Source§ fn borrow(&self) -> &T

Immutably borrows from an owned value.

Read more Source§ impl<T> BorrowMut<T> for T

where T: ?

Sized

,

Source§ fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value.

Read more Source§ impl<T> From<T> for T Source§ fn from(t: T) -> T

Returns the argument unchanged.

Source§ impl<T, U> Into<U> for T

where U:

From

<T>,

Source§ fn into(self) -> U

Calls U::from(self).

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

Source§ impl<T, U> TryFrom<U> for T

where U:

Into

<T>,

Source§ type Error = Infallible

The type returned in the event of a conversion error.

Source§ fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.

Source§ impl<T, U> TryInto<U> for T

where U:

TryFrom

<T>,

Source§ type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

Source§ fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4