gostats

package module
v0.0.0-...-b7b894c Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2014 License: MIT Imports: 6 Imported by: 0

README

gostats

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CalcAverages

func CalcAverages()

func Cpu

func Cpu() int

func CpuAverage

func CpuAverage() int

func MemoryPhysical

func MemoryPhysical() (int, uint64, uint64)

func MemoryPhysicalUsage

func MemoryPhysicalUsage() int

func MemoryVirtual

func MemoryVirtual() (int, uint64, uint64)

func MemoryVirtualUsage

func MemoryVirtualUsage() int

func NetworkInterfaceUsage

func NetworkInterfaceUsage() map[string]Usage

Types

type Interface

type Interface struct {
	Name       string // e.g., "en0", "lo0", "eth0.100"
	BytesIn    int64
	BytesOut   int64
	PacketsIn  int64
	PacketsOut int64
}

type Usage

type Usage struct {
	MegaBitsPerSecondIn  float64 `json:"mbpsIn"   bson:"mbpsIn"`
	MegaBitsPerSecondOut float64 `json:"mbpsOut"  bson:"mbpsOut"`
	PacketsPerSecondIn   float64 `json:"ppsIn"    bson:"ppsIn"`
	PacketsPerSecondOut  float64 `json:"ppsOut"   bson:"ppsOut"`
}

Jump to

Keyboard shortcuts

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