Class: Ya::API::Direct::DirectServiceV5
- Inherits:
-
DirectServiceBase
- Object
- DirectServiceBase
- Ya::API::Direct::DirectServiceV5
- Defined in:
- lib/ya/api/direct/direct_service_v5.rb
Instance Attribute Summary collapse
-
#service ⇒ Object
readonly
Returns the value of attribute service.
-
#service_url ⇒ Object
readonly
Returns the value of attribute service_url.
Attributes inherited from DirectServiceBase
Instance Method Summary collapse
- #exec_request(method, request_body = {}) ⇒ Object
-
#initialize(client, service, methods) ⇒ DirectServiceV5
constructor
A new instance of DirectServiceV5.
Constructor Details
#initialize(client, service, methods) ⇒ DirectServiceV5
Returns a new instance of DirectServiceV5.
8 9 10 11 12 13 |
# File 'lib/ya/api/direct/direct_service_v5.rb', line 8 def initialize(client, service, methods) super(client, methods) @service = service @service_url = service.downcase @version = :v5 end |
Instance Attribute Details
#service ⇒ Object (readonly)
Returns the value of attribute service.
6 7 8 |
# File 'lib/ya/api/direct/direct_service_v5.rb', line 6 def service @service end |
#service_url ⇒ Object (readonly)
Returns the value of attribute service_url.
6 7 8 |
# File 'lib/ya/api/direct/direct_service_v5.rb', line 6 def service_url @service_url end |
Instance Method Details
#exec_request(method, request_body = {}) ⇒ Object
15 16 17 |
# File 'lib/ya/api/direct/direct_service_v5.rb', line 15 def exec_request(method, request_body={}) @client.gateway.request method, request_body, @service_url, @version end |