Panda3D
Public Member Functions | Public Attributes | List of all members
Socket_Selector Struct Reference

Public Member Functions

 Socket_Selector (const Socket_fdset &fd)
 
int WaitFor (const Time_Span &timeout)
 This function is the reason this call exists. More...
 
int WaitFor_All (const Socket_fdset &fd, const Time_Span &timeout)
 Helper function to utilize the WaitFor function. More...
 
int WaitFor_Read_Error (const Socket_fdset &fd, const Time_Span &timeout)
 Helper function for WaitFor Only looks for readability and errors. More...
 
int WaitFor_Write_Error (const Socket_fdset &fd, const Time_Span &timeout)
 Helper function for WaitFor Only looks for writability and errors. More...
 

Public Attributes

int _answer
 
Socket_fdset _error
 
Socket_fdset _read
 
Socket_fdset _write
 

Detailed Description

Definition at line 6 of file socket_selector.h.

Member Function Documentation

◆ WaitFor()

int Socket_Selector::WaitFor ( const Time_Span timeout)
inline

This function is the reason this call exists.

. It will wait for a read, write or error condition on a socket or it will time out

Definition at line 31 of file socket_selector.h.

Referenced by WaitFor_All(), WaitFor_Read_Error(), and WaitFor_Write_Error().

◆ WaitFor_All()

int Socket_Selector::WaitFor_All ( const Socket_fdset fd,
const Time_Span timeout 
)
inline

Helper function to utilize the WaitFor function.

Definition at line 49 of file socket_selector.h.

References WaitFor().

◆ WaitFor_Read_Error()

int Socket_Selector::WaitFor_Read_Error ( const Socket_fdset fd,
const Time_Span timeout 
)
inline

Helper function for WaitFor Only looks for readability and errors.

Definition at line 60 of file socket_selector.h.

References Socket_fdset::clear(), and WaitFor().

◆ WaitFor_Write_Error()

int Socket_Selector::WaitFor_Write_Error ( const Socket_fdset fd,
const Time_Span timeout 
)
inline

Helper function for WaitFor Only looks for writability and errors.

Definition at line 71 of file socket_selector.h.

References Socket_fdset::clear(), and WaitFor().


The documentation for this struct was generated from the following file: