Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetExpirationHandler ¶
GetExpirationHandler returns a potentially long-lived callback that removes the specified object from the storage.
Types ¶
type Scheduler ¶
type Scheduler struct {
// contains filtered or unexported fields
}
Scheduler efficiently manages and executes callbacks at specified times.
func NewScheduler ¶
func NewScheduler() (em *Scheduler)
NewScheduler initializes and returns a newly created Scheduler instance.
func (*Scheduler) AddEvent ¶
func (em *Scheduler) AddEvent(key types.ObjectIDHash, callback func(), expire time.Duration)
AddEvent schedules the passed callback to be executed at the supplied time.
Click to show internal directories.
Click to hide internal directories.