Class: Flatpack::Client::BaseApi
- Inherits:
-
Object
- Object
- Flatpack::Client::BaseApi
- Includes:
- Flatpack::Core::MapInitialize
- Defined in:
- lib/flatpack/client/base_api.rb
Instance Attribute Summary collapse
-
#flatpack ⇒ Object
Returns the value of attribute flatpack.
-
#server_base ⇒ Object
Returns the value of attribute server_base.
-
#verbose ⇒ Object
Returns the value of attribute verbose.
Instance Method Summary collapse
- #annotation_entity_get(entity) ⇒ Object
-
#auth_headers ⇒ Object
Concrete implementations that require authentication should implement this method if authenticated requests require custom request headers.
- #describe_entity_get(entity) ⇒ Object
-
#refresh_session ⇒ Object
Concrete implementations that require authentication should implement this method to refresh an expired session.
-
#session_active? ⇒ Boolean
Concrete implementations that require authentication should implement this method do determine if the current session is still active.
Instance Attribute Details
#flatpack ⇒ Object
Returns the value of attribute flatpack.
8 9 10 |
# File 'lib/flatpack/client/base_api.rb', line 8 def flatpack @flatpack end |
#server_base ⇒ Object
Returns the value of attribute server_base.
8 9 10 |
# File 'lib/flatpack/client/base_api.rb', line 8 def server_base @server_base end |
#verbose ⇒ Object
Returns the value of attribute verbose.
8 9 10 |
# File 'lib/flatpack/client/base_api.rb', line 8 def verbose @verbose end |
Instance Method Details
#annotation_entity_get(entity) ⇒ Object
32 33 34 |
# File 'lib/flatpack/client/base_api.rb', line 32 def annotation_entity_get(entity) annotation_type_uuid_get(entity.entity_name, entity.uuid) end |
#auth_headers ⇒ Object
Concrete implementations that require authentication should implement this method if authenticated requests require custom request headers
24 25 26 |
# File 'lib/flatpack/client/base_api.rb', line 24 def auth_headers return {} end |
#describe_entity_get(entity) ⇒ Object
28 29 30 |
# File 'lib/flatpack/client/base_api.rb', line 28 def describe_entity_get(entity) describe_type_uuid_get(entity.entity_name, entity.uuid) end |
#refresh_session ⇒ Object
Concrete implementations that require authentication should implement this method to refresh an expired session
19 20 |
# File 'lib/flatpack/client/base_api.rb', line 19 def refresh_session end |
#session_active? ⇒ Boolean
Concrete implementations that require authentication should implement this method do determine if the current session is still active.
12 13 14 15 |
# File 'lib/flatpack/client/base_api.rb', line 12 def session_active? # By default, the session is always active true end |