Class: WatsonLanguage::Translator
- Inherits:
-
ActiveMethod::Base
- Object
- ActiveMethod::Extra
- ActiveMethod::Base
- WatsonLanguage::Translator
- Defined in:
- lib/watson-language-translator/translator.rb
Instance Attribute Summary
Attributes inherited from ActiveMethod::Base
#http_method, #json_result, #options, #password, #text, #username
Instance Method Summary collapse
Methods inherited from ActiveMethod::Base
#fetch_http_method, #initialize, #params_addressable, #request
Methods included from Generators::LanguageRequest
#base_url_request, #json_parser, #rest_client_api
Methods inherited from ActiveMethod::Extra
Constructor Details
This class inherits a constructor from WatsonLanguage::ActiveMethod::Base
Instance Method Details
#endpoint ⇒ Object
7 8 9 10 11 12 |
# File 'lib/watson-language-translator/translator.rb', line 7 def endpoint url = "translate" url << "?text=#{@text}" url << "&#{params_addressable}" unless params_addressable.empty? url end |