NetworkManager::TunDevice Class

class NetworkManager::TunDevice

A tun device interface. More...

Header: #include <NetworkManagerQt/TunDevice>
CMake: find_package(KF6 REQUIRED COMPONENTS NetworkManagerQt)
target_link_libraries(mytarget PRIVATE KF6::NetworkManagerQt)
Inherits: NetworkManager::Device

Public Types

Properties

Public Functions

TunDevice(const QString &path, QObject *parent = nullptr)
qlonglong group() const
QString hwAddress() const
QString mode() const
bool multiQueue() const
bool noPi() const
qlonglong owner() const
bool vnetHdr() const

Signals

void groupChanged(qlonglong group)
void hwAddressChanged(const QString &hwAddress)
void modeChanged(const QString &mode)
void multiQueueChanged(bool multiQueue)
void noPiChanged(bool noPi)
void ownerChanged(qlonglong owner)
void vnetHdrChanged(bool vnetHdr)

Detailed Description

Member Type Documentation

TunDevice::List

TunDevice::Ptr

Property Documentation

[read-only] group : const qlonglong

Access functions:

qlonglong group() const

Notifier signal:

void groupChanged(qlonglong group)

[read-only] hwAddress : const QString

Access functions:

QString hwAddress() const

Notifier signal:

void hwAddressChanged(const QString &hwAddress)

[read-only] mode : const QString

Access functions:

QString mode() const

Notifier signal:

void modeChanged(const QString &mode)

[read-only] multiQueue : const bool

Access functions:

bool multiQueue() const

Notifier signal:

void multiQueueChanged(bool multiQueue)

[read-only] noPi : const bool

Access functions:

bool noPi() const

Notifier signal:

void noPiChanged(bool noPi)

[read-only] owner : const qlonglong

Access functions:

qlonglong owner() const

Notifier signal:

void ownerChanged(qlonglong owner)

[read-only] vnetHdr : const bool

Access functions:

bool vnetHdr() const

Notifier signal:

void vnetHdrChanged(bool vnetHdr)

Member Function Documentation

[explicit] TunDevice::TunDevice(const QString &path, QObject *parent = nullptr)

qlonglong TunDevice::group() const

The gid of the tunnel group, or -1 if it has no owner.

Note: Getter function for property group.

[signal] void TunDevice::groupChanged(qlonglong group)

Emitted when the gid of the tunnel group has changed

Note: Notifier signal for property group.

QString TunDevice::hwAddress() const

Hardware address of the device.

Note: Getter function for property hwAddress.

[signal] void TunDevice::hwAddressChanged(const QString &hwAddress)

Emitted when the hardware address of the device has changed

Note: Notifier signal for property hwAddress.

QString TunDevice::mode() const

The tunnel mode, either "tun" or "tap".

Note: Getter function for property mode.

[signal] void TunDevice::modeChanged(const QString &mode)

Emitted when the tunnel mode has changed

Note: Notifier signal for property mode.

bool TunDevice::multiQueue() const

The tunnel's "TUN_TAP_MQ" flag; true if callers can connect to the tap device multiple times, for multiple send/receive queues.

Note: Getter function for property multiQueue.

[signal] void TunDevice::multiQueueChanged(bool multiQueue)

Emitted when the tunnel's "TUN_TAP_MQ" flag has changed

Note: Notifier signal for property multiQueue.

bool TunDevice::noPi() const

The tunnel's "TUN_NO_PI" flag; true if no protocol info is prepended to the tunnel packets.

Note: Getter function for property noPi.

[signal] void TunDevice::noPiChanged(bool noPi)

Emitted when the tunnel's "TUN_NO_PI" flag has changed

Note: Notifier signal for property noPi.

qlonglong TunDevice::owner() const

The uid of the tunnel owner, or -1 if it has no owner.

Note: Getter function for property owner.

[signal] void TunDevice::ownerChanged(qlonglong owner)

Emitted when the uid of the tunnel owner has changed

Note: Notifier signal for property owner.

bool TunDevice::vnetHdr() const

The tunnel's "TUN_VNET_HDR" flag; true if the tunnel packets include a virtio network header.

Note: Getter function for property vnetHdr.

[signal] void TunDevice::vnetHdrChanged(bool vnetHdr)

Emitted when the tunnel's "TUN_VNET_HDR" flag has changed

Note: Notifier signal for property vnetHdr.