Haka: modules/protocol/ipv4/haka/ipv4-network.h File Reference

Haka

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

Data Structures | Macros | Functions | Variables
ipv4-network.h File Reference
`#include <haka/types.h>`

Go to the source code of this file.

## Data Structures
struct | ipv4network

## Macros
#define | IPV4_NETWORK_STRING_MAXLEN 18

## Functions
void | ipv4_network_to_string (ipv4network net, char *string, size_t size)
ipv4network | ipv4_network_from_string (const char *string)
uint8 | ipv4_network_contains (ipv4network network, ipv4addr addr)

## Variables
const ipv4network | ipv4_network_zero

## Detailed Description

IPv4 network API.

## Macro Definition Documentation

#define IPV4_NETWORK_STRING_MAXLEN 18

String max size for converting ipv4network to string.

## Function Documentation

uint8 ipv4_network_contains | ( | ipv4network | network,
|  | ipv4addr | addr
| ) |  |

Checks if IPv4 address is in network range.

Returns
  True if ip address is in network range and False otherwise.

ipv4network ipv4_network_from_string | ( | const char * | string | ) |

Convert network address from string to ipv4network structure.

void ipv4_network_to_string | ( | ipv4network | net,
|  | char * | string,
|  | size_t | size
| ) |  |

Convert network address from ipv4network to string.

## Variable Documentation

const ipv4network ipv4_network_zero

IPv4 network initializer.