link

package
v0.0.0-...-90ffb0e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 9, 2025 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Overview

Package link models a point-to-point network link.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Link struct {
	// contains filtered or unexported fields
}

Link models a link between two [*Stack] instances.

The zero value is not ready to use; construct using New.

func New

func New(left, right LinkStack) *Link

New creates a new *Link using two [*Stack] and sets up moving packets between the two stacks. Use Close to shut down background goroutines.

func (*Link) Close

func (lnk *Link) Close() error

Close stops background goroutines moving traffic.

type LinkStack

type LinkStack = packet.NetworkDevice

LinkStack is the [*Stack] as seen by a *Link.

type Packet

type Packet = packet.Packet

Packet is the packet.Packet alias used by this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL