Class: ProxyRb::ProxyUrlParser
- Inherits:
-
Object
- Object
- ProxyRb::ProxyUrlParser
- Defined in:
- lib/proxy_rb/proxy_url_parser.rb
Overview
Parse urls for proxies
Instance Attribute Summary collapse
-
#credentials ⇒ Object
readonly
Returns the value of attribute credentials.
-
#proxy_url ⇒ Object
readonly
Returns the value of attribute proxy_url.
Instance Method Summary collapse
-
#initialize(url) ⇒ ProxyUrlParser
constructor
A new instance of ProxyUrlParser.
Constructor Details
#initialize(url) ⇒ ProxyUrlParser
Returns a new instance of ProxyUrlParser.
20 21 22 23 24 25 |
# File 'lib/proxy_rb/proxy_url_parser.rb', line 20 def initialize(url) temporary_url = ProxyUrl.parse(url) @proxy_url = temporary_url.without_user_name_and_password @credentials = Credentials.new(temporary_url.user, temporary_url.password) end |
Instance Attribute Details
#credentials ⇒ Object (readonly)
Returns the value of attribute credentials.
16 17 18 |
# File 'lib/proxy_rb/proxy_url_parser.rb', line 16 def credentials @credentials end |
#proxy_url ⇒ Object (readonly)
Returns the value of attribute proxy_url.
16 17 18 |
# File 'lib/proxy_rb/proxy_url_parser.rb', line 16 def proxy_url @proxy_url end |