Exception: Locomotive::Steam::RedirectionException
- Inherits:
-
Exception
- Object
- Exception
- Locomotive::Steam::RedirectionException
- Defined in:
- lib/locomotive/steam/errors.rb
Instance Attribute Summary collapse
-
#permanent ⇒ Object
readonly
Returns the value of attribute permanent.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(url, permanent: false) ⇒ RedirectionException
constructor
A new instance of RedirectionException.
Constructor Details
#initialize(url, permanent: false) ⇒ RedirectionException
Returns a new instance of RedirectionException.
10 11 12 13 14 |
# File 'lib/locomotive/steam/errors.rb', line 10 def initialize(url, permanent: false) @url = url @permanent = permanent super("Redirect to #{url} (#{permanent ? '301': '302'})") end |
Instance Attribute Details
#permanent ⇒ Object (readonly)
Returns the value of attribute permanent.
8 9 10 |
# File 'lib/locomotive/steam/errors.rb', line 8 def permanent @permanent end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
8 9 10 |
# File 'lib/locomotive/steam/errors.rb', line 8 def url @url end |