Documentation
¶
Rendered for darwin/amd64
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( GetAll = getAll GetTemperature = getTemperature GetFans = getFans GetBattery = getBattery GetPower = getPower GetVoltage = getVoltage GetCurrent = getCurrent GetHardware = getHardware )
Monkey-patching hooks for tests. Tests mutate these; never call t.Parallel() in output tests.
Functions ¶
This section is empty.
Types ¶
type InfluxOutput ¶
type InfluxOutput struct {
// contains filtered or unexported fields
}
func (InfluxOutput) All ¶
func (o InfluxOutput) All()
func (InfluxOutput) Battery ¶
func (o InfluxOutput) Battery()
func (InfluxOutput) Current ¶
func (o InfluxOutput) Current()
func (InfluxOutput) Fans ¶
func (o InfluxOutput) Fans()
func (InfluxOutput) Hardware ¶
func (o InfluxOutput) Hardware()
func (InfluxOutput) Power ¶
func (o InfluxOutput) Power()
func (InfluxOutput) Temperature ¶
func (o InfluxOutput) Temperature()
func (InfluxOutput) Voltage ¶
func (o InfluxOutput) Voltage()
type JSONOutput ¶
type JSONOutput struct {
// contains filtered or unexported fields
}
func (JSONOutput) All ¶
func (jo JSONOutput) All()
func (JSONOutput) Battery ¶
func (jo JSONOutput) Battery()
func (JSONOutput) Current ¶
func (jo JSONOutput) Current()
func (JSONOutput) Fans ¶
func (jo JSONOutput) Fans()
func (JSONOutput) Hardware ¶
func (jo JSONOutput) Hardware()
func (JSONOutput) Power ¶
func (jo JSONOutput) Power()
func (JSONOutput) Temperature ¶
func (jo JSONOutput) Temperature()
func (JSONOutput) Voltage ¶
func (jo JSONOutput) Voltage()
type Output ¶
type Output interface {
// All prints all the detected sensors results
All()
// Battery prints the detected battery sensor results
Battery()
// Current prints the current sensor results
Current()
// Fans prints the detected fan sensor results
Fans()
// Hardware prints the detected hardware information
Hardware()
// Temperature prints detected temperature sensor results
Temperature()
// Power prints detected power sensor results
Power()
// Voltage prints detected voltage sensor results
Voltage()
}
func Factory ¶
Factory returns the Output implementation for the given format name. Recognised values are "table", "json", and "influx"; anything else falls back to ASCII table output.
func NewInfluxOutput ¶
func NewInfluxOutput() Output
NewInfluxOutput returns an InfluxOutput that writes to stdout.
func NewJSONOutput ¶
func NewJSONOutput() Output
NewJSONOutput returns a JSONOutput that writes to stdout.
func NewTableOutput ¶
NewTableOutput returns a TableOutput that writes to stdout. When isASCII is true the output uses plain ASCII borders; otherwise a coloured style is applied.
type TableOutput ¶
type TableOutput struct {
// contains filtered or unexported fields
}
func (TableOutput) All ¶
func (to TableOutput) All()
func (TableOutput) Battery ¶
func (to TableOutput) Battery()
func (TableOutput) Current ¶
func (to TableOutput) Current()
func (TableOutput) Fans ¶
func (to TableOutput) Fans()
func (TableOutput) Hardware ¶
func (to TableOutput) Hardware()
func (TableOutput) Power ¶
func (to TableOutput) Power()
func (TableOutput) Temperature ¶
func (to TableOutput) Temperature()
func (TableOutput) Voltage ¶
func (to TableOutput) Voltage()
Click to show internal directories.
Click to hide internal directories.