enet: unix.c File Reference

enet

- Main Page
- Related Pages
- Modules
- Data Structures
- Files

- File List
- Globals

Macros | Typedefs | Functions
unix.c File Reference

ENet Unix system specific functions. More...

`#include <sys/types.h>`
`#include <sys/socket.h>`
`#include <sys/ioctl.h>`
`#include <sys/time.h>`
`#include <arpa/inet.h>`
`#include <netinet/tcp.h>`
`#include <netdb.h>`
`#include <unistd.h>`
`#include <string.h>`
`#include <errno.h>`
`#include <time.h>`
`#include "enet/enet.h"`

## Macros
#define | ENET_BUILDING_LIB 1
#define | MSG_NOSIGNAL 0

## Typedefs
typedef int | socklen_t

## Functions
int | enet_initialize (void)
| Initializes ENet globally. More...
void | enet_deinitialize (void)
| Shuts down ENet globally. More...
enet_uint32 | enet_host_random_seed (void)
enet_uint32 | enet_time_get (void)
| Returns the wall-time in milliseconds. More...
void | enet_time_set (enet_uint32 newTimeBase)
| Sets the current wall-time in milliseconds.
int | enet_address_set_host (ENetAddress *address, const char *name)
| Attempts to resolve the host named by the parameter hostName and sets the host field in the address parameter if successful. More...
int | enet_address_get_host_ip (const ENetAddress *address, char *name, size_t nameLength)
| Gives the printable form of the IP address specified in the address parameter. More...
int | enet_address_get_host (const ENetAddress *address, char *name, size_t nameLength)
| Attempts to do a reverse lookup of the host field in the address parameter. More...
int | enet_socket_bind (ENetSocket socket, const ENetAddress *address)
int | enet_socket_get_address (ENetSocket socket, ENetAddress *address)
int | enet_socket_listen (ENetSocket socket, int backlog)
ENetSocket | enet_socket_create (ENetSocketType type)
int | enet_socket_set_option (ENetSocket socket, ENetSocketOption option, int value)
int | enet_socket_get_option (ENetSocket socket, ENetSocketOption option, int *value)
int | enet_socket_connect (ENetSocket socket, const ENetAddress *address)
ENetSocket | enet_socket_accept (ENetSocket socket, ENetAddress *address)
int | enet_socket_shutdown (ENetSocket socket, ENetSocketShutdown how)
void | enet_socket_destroy (ENetSocket socket)
int | enet_socket_send (ENetSocket socket, const ENetAddress *address, const ENetBuffer *buffers, size_t bufferCount)
int | enet_socket_receive (ENetSocket socket, ENetAddress *address, ENetBuffer *buffers, size_t bufferCount)
int | enet_socketset_select (ENetSocket maxSocket, ENetSocketSet *readSet, ENetSocketSet *writeSet, enet_uint32 timeout)
int | enet_socket_wait (ENetSocket socket, enet_uint32 *condition, enet_uint32 timeout)

## Function Documentation

enet_uint32 enet_time_get | ( | void |  | ) |

Its initial value is unspecified unless otherwise set.

Referenced by enet_host_flush(), and enet_host_service().