All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Connection Management

Data Structures

struct  connection_s


typedef struct connection_s connection_t


connection_tConnection_Add (netadr_t *address, void *object, void(*handler)(connection_t *, void *))
 Add a new connection. More...
void Connection_Del (connection_t *con)
 Delete a connection. More...
connection_tConnection_Find (netadr_t *address)
 Search for an established connection based on the remote address. More...
void Connection_Init (void)
 Initialize the connection management system. More...

Detailed Description

Typedef Documentation

typedef struct connection_s connection_t

Function Documentation

connection_t* Connection_Add ( netadr_t address,
void *  object,
void(*)(connection_t *, void *)  handler 

Add a new connection.

addressThe address of the remote end.
objectConnection specific data. Will be passed to handler.
handlerCallback for handling incoming packets. connection_t::handler
The new connection object.
void Connection_Del ( connection_t con)

Delete a connection.

conThe connection to be deleted.
connection_t* Connection_Find ( netadr_t address)

Search for an established connection based on the remote address.

addressThe remote address.
The connection associated with the remote address, or NULL if not found.
void Connection_Init ( void  )

Initialize the connection management system.