load

package
v0.0.42 Latest Latest
Warning

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

Go to latest
Published: May 30, 2016 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Module = modules.Module{
	Name:           "load",
	CreateInstance: CreateInstance,
}

Functions

func CreateInstance

func CreateInstance(name string, config map[string]interface{}) (m modules.ModuleInstance)

func GetRenderContext

func GetRenderContext() *load.AvgStat

func RenderInstance

func RenderInstance(i modules.ModuleInstance) (t modules.Item)

Types

type LoadInstance

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

func (LoadInstance) Name

func (t LoadInstance) Name() (n string)

func (LoadInstance) RefreshInterval

func (t LoadInstance) RefreshInterval() int

func (LoadInstance) Render

func (t LoadInstance) Render() (item modules.Item)

func (LoadInstance) String

func (t LoadInstance) String() (s string)

type LoadItem

type LoadItem struct {
	Name   string `json:"name"`
	Text   string `json:"full_text"`
	Markup string `json:"markup"`
}

func (LoadItem) Marshal

func (e LoadItem) Marshal() (bytes []byte)

type RenderContext

type RenderContext struct {
	Load5, Load10, Load15 float32
}

Jump to

Keyboard shortcuts

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