Chimera: chimera_0-9/include/network.h File Reference

- Main Page
- Classes
- Files
- Directories

- File List
- File Members

# network.h File Reference

`#include "host.h"`
`#include "jrb.h"`

Go to the source code of this file.

## Defines
#define | NETWORK_PACK_SIZE 65536
## Functions
unsigned long | network_address (void *networkglobal, char *hostname)
void * | network_init (void *logs, int port)
void * | network_activate (void *state)
int | network_send (void *state, ChimeraHost *host, char *data, int size, unsigned long type)

## Define Documentation

#define NETWORK_PACK_SIZE 65536

## Function Documentation

void* network_activate | ( | void * | state | ) |

| network_activate: NEVER RETURNS. Puts the network layer into listen mode. This thread manages acknowledgements, delivers incomming messages to the message handler, and drives the network layer. It should only be called once.

unsigned long network_address | ( | void * | networkglobal,
|  | char * | hostname
| ) |

| network_address: returns the ip address of the hostname#

void* network_init | ( | void * | logs,
|  | int | port
| ) |

| network_init: initiates the networking layer by creating socket and bind it to port#

int network_send | ( | void * | state,
|  | ChimeraHost * | host,
|  | char * | data,
|  | int | size,
|  | unsigned long | type
| ) |

| network_send: host, data, size Sends a message to host, updating the measurement info.