Class: VtApi::ApiVersion Abstract
- Inherits:
-
Object
- Object
- VtApi::ApiVersion
- Defined in:
- lib/vt_api/internal/api_version.rb
Overview
This class is abstract.
Base class for API interfaces.
Direct Known Subclasses
Instance Method Summary collapse
-
#base_url ⇒ String
Get API base URL.
-
#endpoint(_method) ⇒ VtApi::Endpoint
Get API method endpoint interface.
-
#endpoint?(_method) ⇒ Boolean
Check whether given method is defined in interface.
-
#error(_http_code) ⇒ String
Get API HTTP-code description.
-
#error?(_http_code) ⇒ Boolean
Check whether API HTTP-code means error.
-
#version ⇒ String
API interface name/version.
Instance Method Details
#base_url ⇒ String
Get API base URL.
9 10 11 |
# File 'lib/vt_api/internal/api_version.rb', line 9 def base_url '' end |
#endpoint(_method) ⇒ VtApi::Endpoint
Get API method endpoint interface.
40 41 42 |
# File 'lib/vt_api/internal/api_version.rb', line 40 def endpoint(_method) nil end |
#endpoint?(_method) ⇒ Boolean
Check whether given method is defined in interface.
48 49 50 |
# File 'lib/vt_api/internal/api_version.rb', line 48 def endpoint?(_method) false end |
#error(_http_code) ⇒ String
Get API HTTP-code description.
24 25 26 |
# File 'lib/vt_api/internal/api_version.rb', line 24 def error(_http_code) nil end |
#error?(_http_code) ⇒ Boolean
Check whether API HTTP-code means error.
32 33 34 |
# File 'lib/vt_api/internal/api_version.rb', line 32 def error?(_http_code) false end |
#version ⇒ String
API interface name/version.
16 17 18 |
# File 'lib/vt_api/internal/api_version.rb', line 16 def version nil end |