// allowedDuration returns true if the supplied duration is at least one second,
// and no more than one minute. (We expect to refine the lease-length times, but
// these seem like reasonable bounds.)
486480
func allowedDuration(duration time.Duration) bool {
	if duration < time.Second {
		return false
	}
	return duration <= time.Minute
}
641042
func (s *CreateMaintenanceWindowInput) SetDuration(v int64) *CreateMaintenanceWindowInput {
	s.Duration = &v
	return s
}
538456
func (s *Reservation) SetDuration(v int64) *Reservation {
	s.Duration = &v
	return s
}
1282933
func (s *UpdateMaintenanceWindowOutput) SetDuration(v int64) *UpdateMaintenanceWindowOutput {
	s.Duration = &v
	return s
}
1053287
func (s *DeleteReservationOutput) SetDuration(v int64) *DeleteReservationOutput {
	s.Duration = &v
	return s
}
840452
func (self *Commands) IsDuration(value interface{}) error {
	if _, err := timeutil.ParseDuration(fmt.Sprintf("%v", value)); err == nil {
		return nil
	} else {
		return fmt.Errorf("Expected duration value")
	}
}
545665
func (s *Session) SetDuration(v int64) *Session {
	s.Duration = &v
	return s
}
1019414
func (p *PagesBuild) GetDuration() int {
	if p == nil || p.Duration == nil {
		return 0
	}
	return *p.Duration
}
597023
func truncateDuration(d time.Duration) time.Duration {
	for _, t := range durTransactions {
		if d > t.threshold {
			return d.Round(t.round)
		}
	}
	return d
}
1255937
func (s *ApplicationMetrics) SetDuration(v int64) *ApplicationMetrics {
	s.Duration = &v
	return s
}
753102
func (s *UpdateMaintenanceWindowInput) SetDuration(v int64) *UpdateMaintenanceWindowInput {
	s.Duration = &v
	return s
}
17311
func (s *ReservedDBInstance) SetDuration(v int64) *ReservedDBInstance {
	s.Duration = &v
	return s
}
508239
func NewDuration(s string) (duration, error) {
	var e duration
	err := e.FromString(s)
	if err != nil {
		return 0, err
	}
	return e, nil
}
1349402
func (l *ListDuration) AddDuration(d time.Duration) {
	l.Duration = l.Duration + d
	l.TimesInList++
}
649295
func (c *Context) GetDuration(key string) (d time.Duration) {
	if val, ok := c.Get(key); ok && val != nil {
		d, _ = val.(time.Duration)
	}
	return
}
17472
func (p *Provider) backoffDuration() time.Duration {
	// Use the default backoff
	backoff := DefaultBackoff

	// Check for a server specified backoff
	p.backoffLock.Lock()
	if p.backoff != 0 {
		backoff = p.backoff
	}
	if p.noRetry {
		backoff = 0
	}
	p.backoffLock.Unlock()

	return backoff
}
295928
func ToNormalizedDuration(d time.Duration, u time.Duration) int64 {
	return int64(d / u)
}