// Timeouts returns the rolling number of timeouts
545056
func (d *DefaultMetricCollector) Timeouts() *rolling.Number {
	d.mutex.RLock()
	defer d.mutex.RUnlock()
	return d.timeouts
}
765096
func (s *ClusterRerouteService) MasterTimeout(masterTimeout string) *ClusterRerouteService {
	s.masterTimeout = masterTimeout
	return s
}
685915
func (s *IndicesCloseService) MasterTimeout(masterTimeout string) *IndicesCloseService {
	s.masterTimeout = masterTimeout
	return s
}
1294698
func (s *IndexService) Timeout(timeout string) *IndexService {
	s.timeout = timeout
	return s
}
460533
func (s *PutMappingService) Timeout(timeout string) *PutMappingService {
	s.timeout = timeout
	return s
}
1275818
func (s *IndicesUnfreezeService) Timeout(timeout string) *IndicesUnfreezeService {
	s.timeout = timeout
	return s
}
1038251
func Timeout(duration time.Duration) Option {
	return func(r *NBReader) {
		r.forceTimeout = duration
	}
}
504588
func (s *UpdateByQueryService) Timeout(timeout string) *UpdateByQueryService {
	s.timeout = timeout
	return s
}
681405
func (d *ResourceData) Timeout(key string) time.Duration {
	key = strings.ToLower(key)

	// System default of 20 minutes
	defaultTimeout := 20 * time.Minute

	if d.timeouts == nil {
		return defaultTimeout
	}

	var timeout *time.Duration
	switch key {
	case TimeoutCreate:
		timeout = d.timeouts.Create
	case TimeoutRead:
		timeout = d.timeouts.Read
	case TimeoutUpdate:
		timeout = d.timeouts.Update
	case TimeoutDelete:
		timeout = d.timeouts.Delete
	}

	if timeout != nil {
		return *timeout
	}

	if d.timeouts.Default != nil {
		return *d.timeouts.Default
	}

	return defaultTimeout
}
193465
func (s *XPackWatcherPutWatchService) MasterTimeout(masterTimeout string) *XPackWatcherPutWatchService {
	s.masterTimeout = masterTimeout
	return s
}
789402
func (s *IndicesDeleteTemplateService) Timeout(timeout string) *IndicesDeleteTemplateService {
	s.timeout = timeout
	return s
}
111863
func Timeout(t time.Duration) Option {
	return func(o *Options) {
		o.Timeout = t
	}
}
558850
func Timeout(d time.Duration) ConfigOpt {
	return func(c *Config) {
		c.transport.ResponseHeaderTimeout = d
		c.transport.TLSHandshakeTimeout = d
		c.dialer.Timeout = d
	}
}
4585
func (s *IndicesPutMappingService) MasterTimeout(masterTimeout string) *IndicesPutMappingService {
	s.masterTimeout = masterTimeout
	return s
}
392568
func (ae ArangoError) Timeout() bool {
	return ae.HasError && (ae.Code == http.StatusRequestTimeout || ae.Code == http.StatusGatewayTimeout)
}
647360
func (f *MockFunction) Timeout(d time.Duration) *MockFunction {
	f.timeout = d
	return f
}
480545
func (s *DeleteScriptService) MasterTimeout(masterTimeout string) *DeleteScriptService {
	s.masterTimeout = masterTimeout
	return s
}