#include <tunDevice.h>
Public Member Functions | |
TunDevice (const char *dev, const char *dev_type, const char *ifcfg_lp, const char *ifcfg_rnmp) | |
~TunDevice () | |
void | open () |
void | close () |
bool | isOpen () |
short | read (Buffer &buf) |
int | write (Buffer &buf) |
char * | getActualName () |
u_int32_t | getType () |
const char * | getTypeString () |
Static Public Attributes | |
static const u_int32_t | TYPE_UNDEF = 0 |
static const u_int32_t | TYPE_TUN = 1 |
static const u_int32_t | TYPE_TAP = 2 |
Private Member Functions | |
void | operator= (const TunDevice &src) |
TunDevice (const TunDevice &src) | |
Private Attributes | |
Mutex | io_mutex_ |
tuntap * | dev_ |
TunDevice::TunDevice | ( | const char * | dev, | |
const char * | dev_type, | |||
const char * | ifcfg_lp, | |||
const char * | ifcfg_rnmp | |||
) |
TunDevice::~TunDevice | ( | ) |
TunDevice::TunDevice | ( | const TunDevice & | src | ) | [private] |
void TunDevice::open | ( | ) |
void TunDevice::close | ( | ) |
bool TunDevice::isOpen | ( | ) |
short TunDevice::read | ( | Buffer & | buf | ) |
int TunDevice::write | ( | Buffer & | buf | ) |
char * TunDevice::getActualName | ( | ) |
u_int32_t TunDevice::getType | ( | ) |
const char * TunDevice::getTypeString | ( | ) |
void TunDevice::operator= | ( | const TunDevice & | src | ) | [private] |
const u_int32_t TunDevice::TYPE_UNDEF = 0 [static] |
const u_int32_t TunDevice::TYPE_TUN = 1 [static] |
const u_int32_t TunDevice::TYPE_TAP = 2 [static] |
Mutex TunDevice::io_mutex_ [private] |
struct tuntap* TunDevice::dev_ [private] |