Documentation
¶
Index ¶
- Variables
- func ForLog(value any, prec int) string
- func ForWeb(value any, prec int) string
- func Format(value any, prec int) string
- func FormatSep(value any, prec int, separator string) string
- func NewCron(location *time.Location) *cron
- func Since(duration time.Duration) string
- func TimeControl(f func(), name string)
- func TimeControlError(f func() error, name string) error
- func ToTime(value any) (time.Time, error)
- type InterCron
- type InterProvider
- type Provider
- func (p *Provider) Comma() rune
- func (p *Provider) GetDate(ts int64) string
- func (p *Provider) GetDateAndTime(ts int64) (string, string)
- func (p *Provider) GetTime(ts int64) string
- func (p *Provider) GetUTC(str string) (int64, error)
- func (p *Provider) LayoutDate() string
- func (p *Provider) LayoutTime() string
- func (p *Provider) SetComma(comma rune)
- func (p *Provider) SetLayout(layout string)
- func (p *Provider) SetLayoutDate(layout string)
- func (p *Provider) SetLayoutTime(layout string)
- func (p *Provider) SetLocation(name string) error
- func (p *Provider) SetTimeDiff(diff time.Duration)
Constants ¶
This section is empty.
Variables ¶
View Source
var DateSeparator = "."
Functions ¶
func TimeControl ¶ added in v0.1.9
func TimeControl(f func(), name string)
func TimeControlError ¶ added in v0.1.37
Types ¶
type InterProvider ¶ added in v0.1.69
type InterProvider interface {
SetComma(rune)
SetLayout(string)
SetLayoutDate(string)
SetLayoutTime(string)
SetLocation(string) error
SetTimeDiff(time.Duration)
Comma() rune
LayoutDate() string
LayoutTime() string
GetUTC(string) (int64, error)
GetDate(int64) string
GetTime(int64) string
GetDateAndTime(int64) (string, string)
}
type Provider ¶ added in v0.1.69
type Provider struct {
// contains filtered or unexported fields
}
func NewProvider ¶ added in v0.1.69
func NewProvider() *Provider
func (*Provider) GetDateAndTime ¶ added in v0.1.84
func (*Provider) LayoutDate ¶ added in v0.1.69
func (*Provider) LayoutTime ¶ added in v0.1.69
func (*Provider) SetLayoutDate ¶ added in v0.1.69
func (*Provider) SetLayoutTime ¶ added in v0.1.69
func (*Provider) SetLocation ¶ added in v0.1.69
func (*Provider) SetTimeDiff ¶ added in v0.1.69
Click to show internal directories.
Click to hide internal directories.