Documentation
¶
Index ¶
- Constants
- Variables
- type OpenHours
- func (o OpenHours) Add(from, to time.Time) OpenHours
- func (o OpenHours) Match(t time.Time) bool
- func (o OpenHours) NextDate(t time.Time) (bool, time.Time)
- func (o OpenHours) NextDur(t time.Time) (bool, time.Duration)
- func (o OpenHours) String() []string
- func (o OpenHours) When(t time.Time, d time.Duration) *time.Time
Constants ¶
View Source
const ( Monday int = iota + 1 Tuesday Wednesday Thursday Friday Saturday Sunday )
Variables ¶
View Source
var ( // Errors ErrInvalidFormat error = errors.New("invalid format") )
Functions ¶
This section is empty.
Types ¶
type OpenHours ¶
OpenHours ...
func NewMust ¶
NewMust returns a new instance of an openhours or panics on error If loc is nil, UTC is used.
Click to show internal directories.
Click to hide internal directories.