stat

package
v0.0.0-...-33a618f Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2020 License: BSD-3-Clause Imports: 1 Imported by: 2

Documentation

Overview

The stat package provides support for collecting libpcap stats.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Stat

type Stat struct {
	Captured  uint32 // The number of packets captured.
	Received  uint32 // The number of packets received (pre-filter).
	Dropped   uint32 // The number of packets dropped.
	IfDropped uint32 // The number of drops by the interface.
}

Stat is the wrapper for the pcap_stat struct in <pcap.h>.

func (*Stat) JsonString

func (s *Stat) JsonString() string

JsonElement returns and JSON encoded form of the Stat struct.

func (*Stat) String

func (s *Stat) String() string

Provides a human readable output for the Stat struct.

Jump to

Keyboard shortcuts

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