configtype

package
v4.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 16, 2023 License: MPL-2.0 Imports: 2 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Duration

type Duration struct {
	// contains filtered or unexported fields
}

Duration is a wrapper around time.Duration that should be used in config when a duration type is required. We wrap the time.Duration type so that the spec can be extended in the future to support other types of durations (e.g. a duration that is specified in days).

func NewDuration

func NewDuration(d time.Duration) Duration

func (*Duration) Duration

func (d *Duration) Duration() time.Duration

func (Duration) Equal

func (d Duration) Equal(other Duration) bool

func (*Duration) MarshalJSON

func (d *Duration) MarshalJSON() ([]byte, error)

func (*Duration) UnmarshalJSON

func (d *Duration) UnmarshalJSON(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL