libdhcp.h File Reference

#include <sys/types.h>
#include <sys/syslog.h>
#include <stdint.h>
#include <stdarg.h>

Go to the source code of this file.

Data Structures

struct  libdhcp_control_s

Defines

#define LIBDHCP   1
#define LOG_FATAL   8

Typedefs

typedef int(*) LIBDHCP_Callback (struct libdhcp_control_s *control, enum dhcp_state_e state, void *arg)
typedef int(*) LIBDHCP_Error_Handler (struct libdhcp_control_s *ctl, int priority, const char *fmt, va_list ap)
typedef libdhcp_control_s LIBDHCP_Control
typedef enum libdhcp_capability_e LIBDHCP_Capability
typedef int(*) DHCP_Client (LIBDHCP_Control *, int argc, char **argv, char **envp)
typedef enum dhcp_state_e DHCP_State

Enumerations

enum  libdhcp_capability_e {
  DHCP_USE_LEASE_DATABASE = 1, DHCP_USE_PID_FILE = 2, DHCP_CONFIGURE_INTERFACES = 4, DHCP_CONFIGURE_ADDRESSES = 8,
  DHCP_CONFIGURE_ROUTES = 16, DHCP_CONFIGURE_RESOLVER = 32, DHCP_CONFIGURE_RADVD = 64
}
enum  dhcp_state_e {
  DHC4_NBI, DHC4_PREINIT, DHC4_BOUND, DHC4_RENEW,
  DHC4_REBOOT, DHC4_REBIND, DHC4_STOP, DHC4_MEDIUM,
  DHC4_TIMEOUT, DHC4_FAIL, DHC4_EXPIRE, DHC4_RELEASE,
  DHC_TIMEDOUT, DHC6_BOUND, DHC6_REBIND, DHC6_RELEASE
}

Functions

LIBDHCP_Controllibdhcp_control_new (LIBDHCP_Callback callback, LIBDHCP_Capability dhc_cap, time_t timeout, void *arg, LIBDHCP_Error_Handler error_handler, uint8_t log_level)
void libdhcp_control_free (LIBDHCP_Control *)
int libdhcp_call_client (LIBDHCP_Control *, DHCP_Client,...)
char * libdhcp_state_string (DHCP_State, char *buf)
int libdhcp_stderr_logger (struct libdhcp_control_s *ctl, int priority, const char *fmt, va_list ap)
int libdhcp_syslogger (struct libdhcp_control_s *ctl, int priority, const char *fmt, va_list ap)


Detailed Description

API for libdhcp, a minimal interface to the ISC dhcp IPv4 client, and to the dhcpv6 DHCPv6 client libraries, libdhcp4client, and libdhcp6client .

Author:
Jason Vas Dias <jvdias@redhat.com>

Definition in file libdhcp.h.


Generated on Thu Aug 10 22:16:40 2006 for libdhcp by  doxygen 1.4.7