// SetTTL sets the TTL field's value.
513694
func (s *ResourceRecordSet) SetTTL(v int64) *ResourceRecordSet {
	s.TTL = &v
	return s
}
734501
func (s *ClaimDevicesByClaimCodeOutput) SetTotal(v int64) *ClaimDevicesByClaimCodeOutput {
	s.Total = &v
	return s
}
408582
func ValidateTTL(ttl time.Duration) error {
	if ttl < 1*time.Second && ttl != 0 && ttl != NoTTL() {
		return errors.New("TTL is not allowed to set less than 1 second")
	}

	return nil
}
1297971
func TTL(d time.Duration) Option {
	return func(c Cache) error {
		switch oc := c.(type) {
		case *cache:
			oc.ttl = d
			return nil
		default:
			return errors.New(ErrIllegalCache, errorMessages)
		}
	}
}
445627
func (s *Secret) TokenTTL() (time.Duration, error) {
	if s == nil {
		return 0, nil
	}

	if s.Auth != nil && s.Auth.LeaseDuration > 0 {
		return time.Duration(s.Auth.LeaseDuration) * time.Second, nil
	}

	if s.Data == nil || s.Data["ttl"] == nil {
		return 0, nil
	}

	ttl, err := parseutil.ParseDurationSecond(s.Data["ttl"])
	if err != nil {
		return 0, err
	}

	return ttl, nil
}
1261834
func (s *Server) setEtcd(key, value string, ttl uint64) {
	if _, err := s.EtcdClient.Set(key, value, ttl); err != nil {
		log.Println(err)
	}
	if s.logLevel == "debug" {
		log.Println("set", key, "->", value)
	}
}
166244
func (s *DescribeBatchPredictionsInput) SetLT(v string) *DescribeBatchPredictionsInput {
	s.LT = &v
	return s
}
80736
func (s *UpdateTrafficPolicyInstanceInput) SetTTL(v int64) *UpdateTrafficPolicyInstanceInput {
	s.TTL = &v
	return s
}
75843
func (s *OpenIDConnectConfig) SetIatTTL(v int64) *OpenIDConnectConfig {
	s.IatTTL = &v
	return s
}
745228
func (l *Limiter) SetTokenBucketExpirationTTL(ttl time.Duration) *Limiter {
	l.Lock()
	l.tokenBucketExpirationTTL = ttl
	l.Unlock()

	return l
}
579950
func (db *DB) ZTTL(key []byte) (int64, error) {
	if err := checkKeySize(key); err != nil {
		return -1, err
	}

	return db.ttl(ZSetType, key)
}
1101047
func (db *RedisDB) TTL(k string) time.Duration {
	db.master.Lock()
	defer db.master.Unlock()
	return db.ttl[k]
}
1146094
func (db *DB) HTTL(key []byte) (int64, error) {
	if err := checkKeySize(key); err != nil {
		return -1, err
	}

	return db.ttl(HashType, key)
}
534046
func (t *Task) SetTTL(ttl time.Duration) *Task {
	t.ttl = ttl
	return t
}
503912
func (s *CreateTrafficPolicyInstanceInput) SetTTL(v int64) *CreateTrafficPolicyInstanceInput {
	s.TTL = &v
	return s
}
315100
func (_ENSRegistry *ENSRegistryCaller) Ttl(opts *bind.CallOpts, node [32]byte) (uint64, error) {
	var (
		ret0 = new(uint64)
	)
	out := ret0
	err := _ENSRegistry.contract.Call(opts, out, "ttl", node)
	return *ret0, err
}
250097
func (s *TrafficPolicyInstance) SetTTL(v int64) *TrafficPolicyInstance {
	s.TTL = &v
	return s
}