gstat/commands/memory.go
Augusto Dwenger J. f004c93773 refactor: implement single point for json marshal
This implementation still isn't perfect. One of the encoutered problems
is that it does not omit Memory sturcts that are technicly empty.
Resulting in JSON with empty objects. This should be a problem for other
parsers but it doesn't look good.
2021-01-02 18:10:16 +01:00

8 lines
150 B
Go

package commands
// Memory usage representation.
type Memory struct {
Used uint64 `json:"used,omitempty"`
Total uint64 `json:"total,omitempty"`
}