netcard

package
v0.1.15 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

*

  • ______ __
  • /\__ _\ /\ \
  • \/_/\ \/ ___ __\ \ \ __ ___ ___ __
  • \ \ \ / ___\ / __ \ \ \ __ / __ \ / _ \ / ___\ / __ \
  • \_\ \__/\ \__//\ __/\ \ \_\ \/\ \_\ \_/\ \/\ \/\ \__//\ __/
  • /\_____\ \____\ \____\\ \____/\ \__/ \_\ \_\ \_\ \____\ \____\
  • \/_____/\/____/\/____/ \/___/ \/__/\/_/\/_/\/_/\/____/\/____/ * *
  • @寒冰
  • www.icezzz.cn
  • hanbin020706@163.com

*

  • ______ __
  • /\__ _\ /\ \
  • \/_/\ \/ ___ __\ \ \ __ ___ ___ __
  • \ \ \ / ___\ / __ \ \ \ __ / __ \ / _ \ / ___\ / __ \
  • \_\ \__/\ \__//\ __/\ \ \_\ \/\ \_\ \_/\ \/\ \/\ \__//\ __/
  • /\_____\ \____\ \____\\ \____/\ \__/ \_\ \_\ \_\ \____\ \____\
  • \/_____/\/____/\/____/ \/___/ \/__/\/_/\/_/\/_/\/____/\/____/ * *
  • @寒冰
  • www.icezzz.cn
  • hanbin020706@163.com

*

  • ______ __
  • /\__ _\ /\ \
  • \/_/\ \/ ___ __\ \ \ __ ___ ___ __
  • \ \ \ / ___\ / __ \ \ \ __ / __ \ / _ \ / ___\ / __ \
  • \_\ \__/\ \__//\ __/\ \ \_\ \/\ \_\ \_/\ \/\ \/\ \__//\ __/
  • /\_____\ \____\ \____\\ \____/\ \__/ \_\ \_\ \_\ \____\ \____\
  • \/_____/\/____/\/____/ \/___/ \/__/\/_/\/_/\/_/\/____/\/____/ * *
  • @寒冰
  • www.icezzz.cn
  • hanbin020706@163.com

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Analyzer

type Analyzer struct {
	Nc      *NetCard // 网卡
	Running bool     // 是否在运行
	// contains filtered or unexported fields
}

func (*Analyzer) Capture

func (anl *Analyzer) Capture()

func (*Analyzer) GetDownSpeed

func (anl *Analyzer) GetDownSpeed() float32

func (*Analyzer) GetUpSpeed

func (anl *Analyzer) GetUpSpeed() float32

func (*Analyzer) Init

func (anl *Analyzer) Init()

func (*Analyzer) Stop

func (anl *Analyzer) Stop()

type NetCard

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

func GetNetCardsWithIPv4Addr

func GetNetCardsWithIPv4Addr() ([]NetCard, error)

得到所有具有IPv4地址的网卡

func (*NetCard) GetIPv4Addr

func (nc *NetCard) GetIPv4Addr() string

func (*NetCard) GetMacAddr

func (nc *NetCard) GetMacAddr() string

func (*NetCard) GetName

func (nc *NetCard) GetName() string

Jump to

Keyboard shortcuts

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