Go to the source code of this file.
◆ SOPC_InternalSocket
typedef struct SOPC_InternalSocket SOPC_InternalSocket |
◆ SOPC_Socket_State
Enumerator |
---|
SOCKET_STATE_CLOSED | |
SOCKET_STATE_CONNECTING | Client connect waiting for write event && SO_ERROR to be verified on event to confirm connection accepted
|
SOCKET_STATE_CONNECTED | Client: write event received after connect / Server: connection accepted (socket level
|
SOCKET_STATE_LISTENING | Server: listening socket
|
SOCKET_STATE_ACCEPTED | Server: accepted socket connection at socket level only (missing SC connection level)
|
◆ SOPC_SocketsInternalContext_Initialize()
void SOPC_SocketsInternalContext_Initialize |
( |
void | | ) |
|
Initialize the array of sockets.
◆ SOPC_SocketsInternalContext_Clear()
void SOPC_SocketsInternalContext_Clear |
( |
void | | ) |
|
Clear the array of sockets.
◆ SOPC_SocketsInternalContext_GetFreeSocket()
Returns an unused socket from the array of sockets or NULL if none available In case socket is not a listnener, the write buffer queue is initialized. Note: caller must lock the mutex before calling it.
◆ SOPC_SocketsInternalContext_CloseSocket()
void SOPC_SocketsInternalContext_CloseSocket |
( |
uint32_t | socketIdx | ) |
|
Close the socket and set it as not used anymore.
◆ SOPC_Sockets_Emit()
Emits an output event to the recorded output event handler socketsEventHandler.
◆ SOPC_Sockets_EnqueueInputEvent()
Enqueues an input event to the queue of events managed by the socket event manager.
◆ SOPC_Sockets_DequeueAndDispatchInputEvent()
Dequeues an input event of the queue of events and call the event dispatcher of the socket event manager. If an event was dispatched SOPC_STATUS_OK is returned, if the queue is empty SOPC_STATUS_WOULD_BLOCK is returned.
◆ socketsArray
Array containing all sockets that can be used.
◆ socketsEventHandler
◆ maxBufferSize