Exception: T2Server::ConnectionRedirectError
- Inherits:
-
T2ServerError
- Object
- RuntimeError
- T2ServerError
- T2Server::ConnectionRedirectError
- Defined in:
- lib/t2-server/exceptions.rb
Overview
Raised if the server wishes to redirect the connection. This typically happens if a client tries to connect to a https server vis a http uri.
Instance Attribute Summary collapse
-
#redirect ⇒ Object
readonly
The redirected connection.
Instance Method Summary collapse
-
#initialize(connection) ⇒ ConnectionRedirectError
constructor
Create a new ConnectionRedirectError with the new, redirected, connection supplied.
Constructor Details
#initialize(connection) ⇒ ConnectionRedirectError
Create a new ConnectionRedirectError with the new, redirected, connection supplied.
211 212 213 214 215 |
# File 'lib/t2-server/exceptions.rb', line 211 def initialize(connection) @redirect = connection super "The server returned an unhandled redirect to '#{@redirect}'." end |
Instance Attribute Details
#redirect ⇒ Object (readonly)
The redirected connection
207 208 209 |
# File 'lib/t2-server/exceptions.rb', line 207 def redirect @redirect end |