MCPcopy
hub / github.com/robfig/cron / WithChain

Function WithChain

option.go:34–38  ·  view source on GitHub ↗

WithChain specifies Job wrappers to apply to all jobs added to this cron. Refer to the Chain* functions in this package for provided wrappers.

(wrappers ...JobWrapper)

Source from the content-addressed store, hash-verified

32// WithChain specifies Job wrappers to apply to all jobs added to this cron.
33// Refer to the Chain* functions in this package for provided wrappers.
34func WithChain(wrappers ...JobWrapper) Option {
35 return func(c *Cron) {
36 c.chain = NewChain(wrappers...)
37 }
38}
39
40// WithLogger uses the provided logger.
41func WithLogger(logger Logger) Option {

Callers 3

TestFuncPanicRecoveryFunction · 0.85
TestJobPanicRecoveryFunction · 0.85
newWithSecondsFunction · 0.85

Calls 1

NewChainFunction · 0.85

Tested by 3

TestFuncPanicRecoveryFunction · 0.68
TestJobPanicRecoveryFunction · 0.68
newWithSecondsFunction · 0.68