summaryrefslogtreecommitdiff
path: root/bar.go
blob: 159de50479f39677dcdef44aa92c198dfd297bcb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package main

import "time"

// Bar is the struct that holds each of the modules and displays the data from them
type Bar struct {
	Modules     []Module
	RefreshRate time.Duration
}

func (b Bar) Display() string {
	var val string

	for _, mod := range b.Modules {
		s, _ := mod.GetInfo()
		val += "[" + s + "]"
	}

	return val
}