UniMRCP  1.7.0
Functions
apt_net.h File Reference

Network Utilities. More...

#include "apt.h"
Include dependency graph for apt_net.h:

Go to the source code of this file.

Functions

APT_BEGIN_EXTERN_C apt_bool_t apt_ip_get (char **addr, apr_pool_t *pool)
 
apt_bool_t apt_ip_get_by_iface (const char *iface_name, char **addr, apr_pool_t *pool)
 
void apt_ntp_time_get (apr_uint32_t *sec, apr_uint32_t *frac)
 

Detailed Description

Network Utilities.

Function Documentation

◆ apt_ip_get()

APT_BEGIN_EXTERN_C apt_bool_t apt_ip_get ( char **  addr,
apr_pool_t *  pool 
)

Get the IP address (in numeric address string format) by hostname.

Parameters
addrthe IP address to return
poolthe pool to allocate memory from

◆ apt_ip_get_by_iface()

apt_bool_t apt_ip_get_by_iface ( const char *  iface_name,
char **  addr,
apr_pool_t *  pool 
)

Get the IP address (in numeric address string format) by network interface name.

Parameters
iface_namethe network interface name (eth0, Local Area Connection, etc)
addrthe IP address to return
poolthe pool to allocate memory from

◆ apt_ntp_time_get()

void apt_ntp_time_get ( apr_uint32_t *  sec,
apr_uint32_t *  frac 
)

Get current NTP time

Parameters
secthe seconds of the NTP time to return
fracthe fractions of the NTP time to return