mirror of
https://github.com/status-im/go-waku.git
synced 2025-01-15 00:04:36 +00:00
28 lines
407 B
Go
28 lines
407 B
Go
package timesource
|
|
|
|
import (
|
|
"context"
|
|
"time"
|
|
)
|
|
|
|
type WallClockTimeSource struct {
|
|
}
|
|
|
|
func NewDefaultClock() *WallClockTimeSource {
|
|
return &WallClockTimeSource{}
|
|
}
|
|
|
|
func (t *WallClockTimeSource) Now() time.Time {
|
|
return time.Now()
|
|
}
|
|
|
|
func (t *WallClockTimeSource) Start(ctx context.Context) error {
|
|
// Do nothing
|
|
return nil
|
|
}
|
|
|
|
func (t *WallClockTimeSource) Stop() error {
|
|
// Do nothing
|
|
return nil
|
|
}
|