Class: YandexDetector::Config
- Inherits:
-
Object
- Object
- YandexDetector::Config
- Defined in:
- lib/yandex_detector/config.rb
Constant Summary collapse
- API_URL =
URL of API service according documentation http://api.yandex.ru/detector/doc/dg/concepts/detector-request.xml
'http://phd.yandex.net/detect/'
- ERROR_TAG_NAME =
Error’s tag name according documentation http://api.yandex.ru/detector/doc/dg/concepts/detector-response.xml
'yandex-mobile-info-error'
- @@timeout =
2
Class Method Summary collapse
-
.timeout ⇒ Integer
Timeout in seconds to API service call.
-
.timeout=(timeout_value = nil) ⇒ Object
Set timeout value to API service call in seconds only if integer value passed.
Class Method Details
.timeout ⇒ Integer
Returns timeout in seconds to API service call.
14 15 16 |
# File 'lib/yandex_detector/config.rb', line 14 def self.timeout @@timeout end |
.timeout=(timeout_value = nil) ⇒ Object
Set timeout value to API service call in seconds only if integer value passed
20 21 22 |
# File 'lib/yandex_detector/config.rb', line 20 def self.timeout=(timeout_value = nil) @@timeout = timeout_value if timeout_value.is_a?(Integer) end |