Exception: RubyReactor::RateLimit::ExceededError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/ruby_reactor/rate_limit.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, retry_after_seconds:, key_base:, limit:, period_seconds:, period_name:) ⇒ ExceededError

Returns a new instance of ExceededError.



18
19
20
21
22
23
24
25
# File 'lib/ruby_reactor/rate_limit.rb', line 18

def initialize(message, retry_after_seconds:, key_base:, limit:, period_seconds:, period_name:)
  super(message)
  @retry_after_seconds = retry_after_seconds
  @key_base = key_base
  @limit = limit
  @period_seconds = period_seconds
  @period_name = period_name
end

Instance Attribute Details

#key_baseObject (readonly)

Returns the value of attribute key_base.



16
17
18
# File 'lib/ruby_reactor/rate_limit.rb', line 16

def key_base
  @key_base
end

#limitObject (readonly)

Returns the value of attribute limit.



16
17
18
# File 'lib/ruby_reactor/rate_limit.rb', line 16

def limit
  @limit
end

#period_nameObject (readonly)

Returns the value of attribute period_name.



16
17
18
# File 'lib/ruby_reactor/rate_limit.rb', line 16

def period_name
  @period_name
end

#period_secondsObject (readonly)

Returns the value of attribute period_seconds.



16
17
18
# File 'lib/ruby_reactor/rate_limit.rb', line 16

def period_seconds
  @period_seconds
end

#retry_after_secondsObject (readonly)

Returns the value of attribute retry_after_seconds.



16
17
18
# File 'lib/ruby_reactor/rate_limit.rb', line 16

def retry_after_seconds
  @retry_after_seconds
end