Class: Fortnox::API::Repository::Base::Options
- Inherits:
-
Object
- Object
- Fortnox::API::Repository::Base::Options
- Defined in:
- lib/fortnox/api/repositories/base/options.rb
Instance Attribute Summary collapse
-
#attr_to_json_map ⇒ Object
Returns the value of attribute attr_to_json_map.
-
#json_collection_wrapper ⇒ Object
Returns the value of attribute json_collection_wrapper.
-
#json_entity_wrapper ⇒ Object
Returns the value of attribute json_entity_wrapper.
-
#json_to_attr_map ⇒ Object
Returns the value of attribute json_to_attr_map.
-
#keys_filtered_on_save ⇒ Object
Returns the value of attribute keys_filtered_on_save.
-
#unique_id ⇒ Object
Returns the value of attribute unique_id.
-
#uri ⇒ Object
Returns the value of attribute uri.
Instance Method Summary collapse
-
#initialize(uri:, json_collection_wrapper:, json_entity_wrapper:, unique_id:, attribute_name_to_json_key_map: {}, keys_filtered_on_save: [ :url ]) ⇒ Options
constructor
A new instance of Options.
Constructor Details
#initialize(uri:, json_collection_wrapper:, json_entity_wrapper:, unique_id:, attribute_name_to_json_key_map: {}, keys_filtered_on_save: [ :url ]) ⇒ Options
Returns a new instance of Options.
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 11 def initialize( uri:, json_collection_wrapper:, json_entity_wrapper:, unique_id:, attribute_name_to_json_key_map: {}, keys_filtered_on_save: [ :url ] ) @uri = uri @json_collection_wrapper = json_collection_wrapper @json_entity_wrapper = json_entity_wrapper @unique_id = unique_id @attr_to_json_map = attribute_name_to_json_key_map @json_to_attr_map = @attr_to_json_map.invert @keys_filtered_on_save = keys_filtered_on_save end |
Instance Attribute Details
#attr_to_json_map ⇒ Object
Returns the value of attribute attr_to_json_map.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def attr_to_json_map @attr_to_json_map end |
#json_collection_wrapper ⇒ Object
Returns the value of attribute json_collection_wrapper.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def json_collection_wrapper @json_collection_wrapper end |
#json_entity_wrapper ⇒ Object
Returns the value of attribute json_entity_wrapper.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def json_entity_wrapper @json_entity_wrapper end |
#json_to_attr_map ⇒ Object
Returns the value of attribute json_to_attr_map.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def json_to_attr_map @json_to_attr_map end |
#keys_filtered_on_save ⇒ Object
Returns the value of attribute keys_filtered_on_save.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def keys_filtered_on_save @keys_filtered_on_save end |
#unique_id ⇒ Object
Returns the value of attribute unique_id.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def unique_id @unique_id end |
#uri ⇒ Object
Returns the value of attribute uri.
7 8 9 |
# File 'lib/fortnox/api/repositories/base/options.rb', line 7 def uri @uri end |