pub struct TcpListener { /* private fields */ }Implementations§
Source§impl TcpListener
TcpListener API Implementation
Tcp Listener is maintained by RSM, every tcp connection is accepted automatically by rsm
and each connection is dispatched to the component by loadbalance policy set by caller
the default LB policy is hashed by the component’s task instanced number
impl TcpListener
TcpListener API Implementation Tcp Listener is maintained by RSM, every tcp connection is accepted automatically by rsm and each connection is dispatched to the component by loadbalance policy set by caller the default LB policy is hashed by the component’s task instanced number
pub fn new( local_addr: &SocketAddr, max_back_log: i32, policy: SOCKET_LB_POLICY, ) -> Result<Self, RESULT>
pub fn close(&mut self) -> RESULT
pub fn get_lb_policy(&self) -> Result<SOCKET_LB_POLICY, RESULT>
pub fn get_sock_id(&self) -> i32
Sourcepub fn get_os_socket(&self) -> RawFdType
pub fn get_os_socket(&self) -> RawFdType
get underlying os raw socket id
Trait Implementations§
Source§impl Clone for TcpListener
impl Clone for TcpListener
Source§fn clone(&self) -> TcpListener
fn clone(&self) -> TcpListener
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TcpListener
impl RefUnwindSafe for TcpListener
impl Send for TcpListener
impl Sync for TcpListener
impl Unpin for TcpListener
impl UnwindSafe for TcpListener
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more