Versions in this module Expand all Collapse all v0 v0.1.2 Jun 30, 2021 Changes in this version type Size + func (s Size) Format(f fmt.State, verb rune) v0.1.1 Apr 15, 2021 v0.1.0 Feb 9, 2021 Changes in this version + const Byte + const GB + const GiB + const KB + const KiB + const MB + const MiB + const PB + const PiB + const TB + const TiB + type Base int + const Binary + const Metric + type NullSize struct + Size Size + Valid bool + func (s *NullSize) Scan(value interface{}) error + func (s *NullSize) UnmarshalJSON(value []byte) error + func (s NullSize) MarshalJSON() ([]byte, error) + func (s NullSize) Value() (driver.Value, error) + type Size struct + Base Base + func New(bytes int64, base Base) *Size + func Parse(s string) (*Size, error) + func (s *Size) Add(y Size) + func (s *Size) Cmp(y Size) int + func (s *Size) Equal(y Size) bool + func (s *Size) Int64() int64 + func (s *Size) IsZero() bool + func (s *Size) Neg() + func (s *Size) Scan(value interface{}) error + func (s *Size) SetInt64(bytes int64) + func (s *Size) Sign() int + func (s *Size) String() string + func (s *Size) Sub(y Size) + func (s *Size) UnmarshalJSON(value []byte) error + func (s *Size) UnmarshalText(value []byte) error + func (s Size) MarshalJSON() ([]byte, error) + func (s Size) MarshalText() ([]byte, error) + func (s Size) Value() (driver.Value, error)