Class: NameChecker::WhoisChecker
- Inherits:
-
Object
- Object
- NameChecker::WhoisChecker
show all
- Includes:
- Logging
- Defined in:
- lib/name_checker/whois_checker.rb
Class Method Summary
collapse
Methods included from Logging
infer_level, logger, #logger
Class Method Details
.check(host, options = {}) ⇒ Object
6
7
8
9
10
11
12
|
# File 'lib/name_checker/whois_checker.rb', line 6
def self.check(host, options = {})
res = Whois.available?(host)
Availability.new(@service_name, res)
rescue Timeout::Error, Whois::Error
Availability.new(@service_name, 'unknown')
end
|