cmds

package
v2.0.0-alpha.1+incompa... Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2018 License: GPL-2.0, GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect(server string) (conn net.Conn)

Connect will returns a socket connection from the server

func Ping

func Ping(conn net.Conn) (ms int64)

Ping issues and times a ping command

func Version

func Version(conn net.Conn) (version string)

Version retrieves and parses the protocol version

Types

type Result

type Result struct {
	Start      time.Time
	Finish     time.Time
	DurationMs int64
	Bytes      int
}

func Download

func Download(conn net.Conn, numbytes int) (result Result)

Download performs a timed download, returning the mpbs

func Upload

func Upload(conn net.Conn, numbytes int) (result Result)

Upload performs a timed upload of numbytes random bytes, returning the mpbs

Jump to

Keyboard shortcuts

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