WvStreams
wvtundev.h
1/* -*- Mode: C++ -*-
2 * Worldvisions Weaver Software:
3 * Copyright (C) 1997-2002 Net Integration Technologies, Inc.
4 *
5 * A tun device wrapper.
6 */
7#ifndef __WV_TUNDEV_H
8#define __WV_TUNDEV_H
9
10#include "wvfile.h"
11#include "wvinterface.h"
12#include "wvaddr.h"
13
21class WvTunDev : public WvFile
22{
23public:
30 WvTunDev(const WvIPNet &addr, int mtu = 1400);
31
34
35private:
36 void init(const WvIPNet &addr, int mtu);
37
38public:
39 const char *wstype() const { return "WvTunDev"; }
40};
41
42
43#endif
WvFile implements a stream connected to a file or Unix device.
Definition: wvfile.h:29
An IP network comprises two WvIPAddr structures: an address and a netmask.
Definition: wvaddr.h:313
WvString is an implementation of a simple and efficient printable-string class.
Definition: wvstring.h:330
WvTunDev provides a convenient way of using Linux tunnel devices.
Definition: wvtundev.h:22
WvTunDev(const WvIPNet &addr, int mtu=1400)
Creates a tunnel device and its associated interface.
Definition: wvtundev.cc:18
WvString ifcname
Contains the name of the interface associated with the device.
Definition: wvtundev.h:33