Documentation
¶
Index ¶
- Constants
- func GetCurrentCPU() float64
- func GetCurrentKernelDisk() float64
- func GetCurrentMainDisk() uint64
- func GetCurrentMem() float64
- func GetTotalKernelDisk() uint64
- func GetTotalMainDisk() uint64
- func LoadTop(path string, fn func(map[string]any))
- type CircleQueue
- type PercentData
- type UsageStat
Constants ¶
View Source
const (
TopQueneCap = 30
)
Variables ¶
This section is empty.
Functions ¶
func GetCurrentCPU ¶
func GetCurrentCPU() float64
func GetCurrentKernelDisk ¶
func GetCurrentKernelDisk() float64
func GetCurrentMainDisk ¶
func GetCurrentMainDisk() uint64
func GetCurrentMem ¶
func GetCurrentMem() float64
func GetTotalKernelDisk ¶
func GetTotalKernelDisk() uint64
func GetTotalMainDisk ¶
func GetTotalMainDisk() uint64
Types ¶
type CircleQueue ¶
type CircleQueue struct {
// contains filtered or unexported fields
}
CircleQueue 环形队列
func (*CircleQueue) Last ¶
func (c *CircleQueue) Last() *PercentData
type PercentData ¶
type PercentData struct { Time orm.Time `json:"time"` Used float64 `json:"used"` Up float64 `json:"up"` Down float64 `json:"down"` }
PercentData 时间百分比
func GetCPUData ¶
func GetCPUData() []PercentData
func GetMemData ¶
func GetMemData() []PercentData
func GetNetData ¶
func GetNetData() []PercentData
Click to show internal directories.
Click to hide internal directories.