Class: HideMyAss::Proxy::Hidester
- Defined in:
- lib/hidemyass/proxy/hidester.rb
Overview
Represent one proxy instance from hidester.com/proxylist
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#anonymity ⇒ String
The level of anonymity in downcase letters.
-
#country ⇒ String
The country where the proxy is hosted in downcase letters.
-
#ip ⇒ String
The IP of the proxy server.
-
#last_check ⇒ Int
Time in minutes when its been last checked.
-
#port ⇒ Int
The port for the proxy.
-
#speed ⇒ Int
The average response time in milliseconds.
-
#type ⇒ String
The network protocol in in downcase letters.
Methods inherited from Base
#anonym?, #http?, #https?, #initialize, #inspect, #protocol, #rel_url, #secure?, #socks?, #ssl?, #url
Constructor Details
This class inherits a constructor from HideMyAss::Proxy::Base
Instance Method Details
#anonymity ⇒ String
The level of anonymity in downcase letters. (low, medium, high, …)
47 48 49 50 51 52 53 |
# File 'lib/hidemyass/proxy/hidester.rb', line 47 def anonymity case @row['anonymity'] when 'Elite' then 'high' when 'Anonymous' then 'medium' else 'no' end end |
#country ⇒ String
The country where the proxy is hosted in downcase letters.
24 25 26 |
# File 'lib/hidemyass/proxy/hidester.rb', line 24 def country @row['country'].downcase end |
#ip ⇒ String
The IP of the proxy server.
10 11 12 |
# File 'lib/hidemyass/proxy/hidester.rb', line 10 def ip @row['IP'] end |
#last_check ⇒ Int
Time in minutes when its been last checked.
58 59 60 61 |
# File 'lib/hidemyass/proxy/hidester.rb', line 58 def last_check require 'time' ((Time.now - Time.at(@row['latest_check'])) / 60).round end |
#port ⇒ Int
The port for the proxy.
17 18 19 |
# File 'lib/hidemyass/proxy/hidester.rb', line 17 def port @row['PORT'] end |
#speed ⇒ Int
The average response time in milliseconds.
31 32 33 |
# File 'lib/hidemyass/proxy/hidester.rb', line 31 def speed @row['ping'] end |
#type ⇒ String
The network protocol in in downcase letters. (https or http or socks)
39 40 41 |
# File 'lib/hidemyass/proxy/hidester.rb', line 39 def type @row['type'] end |