Index | Files

package diskio

import ""

Package diskio implements an i3bar module to show disk IO rates.


Package Files


func RefreshInterval Uses

func RefreshInterval(interval time.Duration)

RefreshInterval configures the polling frequency.

type IO Uses

type IO struct {
    Input, Output unit.Datarate
    // contains filtered or unexported fields

IO represents input and output rates for a disk.

func (IO) Total Uses

func (i IO) Total() unit.Datarate

Total gets the total IO rate (input + output).

type Module Uses

type Module struct {
    // contains filtered or unexported fields

Module represents a bar.Module for a single disk's io activity.

func New Uses

func New(disk string) *Module

New creates a diskio module that displays disk io rates for the given disk.

func (*Module) Output Uses

func (m *Module) Output(outputFunc func(IO) bar.Output) *Module

Output configures a module to display the output of a user-defined function.

func (*Module) Stream Uses

func (m *Module) Stream(s bar.Sink)

Stream starts the module. Note that diskio updates begin as soon as the first module is constructed, even if no modules are streaming.

Package diskio imports 13 packages (graph) and is imported by 1 packages. Updated 2018-11-25. Refresh now. Tools for package owners.