Documentation
¶
Index ¶
- Constants
- func FormatBytes(s uint64) string
- func FormatIBytes(s uint64) string
- func FormatKBytes(s uint64) string
- func FormatKIBytes(s uint64) string
- func FormatMemoryBytes(s uint64) string
- func FormatMemoryKBytes(s uint64) string
- type Bytes
- type MemoryBytes
- type NetworkBytes
- type NetworkBytesCompat
Constants ¶
View Source
const ( Byte = 1 << (iota * 10) KiByte MiByte GiByte TiByte PiByte EiByte )
Variables ¶
This section is empty.
Functions ¶
func FormatBytes ¶
func FormatIBytes ¶
func FormatKBytes ¶ added in v0.7.15
func FormatKIBytes ¶ added in v0.7.15
func FormatMemoryBytes ¶
func FormatMemoryKBytes ¶ added in v0.7.15
Types ¶
type Bytes ¶
type Bytes struct {
// contains filtered or unexported fields
}
func (Bytes) MarshalJSON ¶
func (*Bytes) UnmarshalJSON ¶
type MemoryBytes ¶
type MemoryBytes struct {
// contains filtered or unexported fields
}
func (MemoryBytes) MarshalJSON ¶
func (*MemoryBytes) UnmarshalJSON ¶
func (m *MemoryBytes) UnmarshalJSON(bytes []byte) error
func (*MemoryBytes) Value ¶
func (m *MemoryBytes) Value() uint64
type NetworkBytes ¶
type NetworkBytes struct {
// contains filtered or unexported fields
}
func (NetworkBytes) MarshalJSON ¶
func (*NetworkBytes) UnmarshalJSON ¶
func (n *NetworkBytes) UnmarshalJSON(bytes []byte) error
func (*NetworkBytes) Value ¶
func (n *NetworkBytes) Value() uint64
type NetworkBytesCompat ¶
type NetworkBytesCompat struct {
// contains filtered or unexported fields
}
func (NetworkBytesCompat) MarshalJSON ¶
func (*NetworkBytesCompat) UnmarshalJSON ¶
func (n *NetworkBytesCompat) UnmarshalJSON(bytes []byte) error
func (*NetworkBytesCompat) Value ¶
func (n *NetworkBytesCompat) Value() uint64
Click to show internal directories.
Click to hide internal directories.