Documentation ¶
Index ¶
- type Monitor
- func (c *Monitor) ByteCountIEC(b uint64) string
- func (c *Monitor) ByteCountSI(b uint64) string
- func (c *Monitor) Get() *proto.MonitorResponse
- func (c *Monitor) RegisterChannel(id string, channel chan *proto.MonitorResponse)
- func (c *Monitor) Round(num float64) int
- func (c *Monitor) Start()
- func (c *Monitor) Stats() (err error)
- func (c *Monitor) ToFixed(num float64, precision int) float64
- func (c *Monitor) UnRegisterChannel(id string)
- type Stat
- type SysInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Monitor ¶
func NewMonitor ¶
func NewMonitor(lo interfaces.Listener) *Monitor
func (*Monitor) ByteCountIEC ¶
func (*Monitor) ByteCountSI ¶
func (*Monitor) Get ¶
func (c *Monitor) Get() *proto.MonitorResponse
Get returns the current monitor data, don't use this, data is not thread safe Using RegisterChannel and UnRegisterChannel instead
func (*Monitor) RegisterChannel ¶ added in v1.2.8
func (c *Monitor) RegisterChannel(id string, channel chan *proto.MonitorResponse)
func (*Monitor) UnRegisterChannel ¶ added in v1.2.8
Click to show internal directories.
Click to hide internal directories.