Class: AbcJsonapi::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/abc_jsonapi.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



17
18
19
20
21
# File 'lib/abc_jsonapi.rb', line 17

def initialize
  @transform_keys ||= true
  @key_transform_method ||= 'camel' # snake or camel
  @pluralize_resources ||= false
end

Instance Attribute Details

#key_transform_methodObject

Returns the value of attribute key_transform_method.



15
16
17
# File 'lib/abc_jsonapi.rb', line 15

def key_transform_method
  @key_transform_method
end

#pluralize_resourcesObject

Returns the value of attribute pluralize_resources.



15
16
17
# File 'lib/abc_jsonapi.rb', line 15

def pluralize_resources
  @pluralize_resources
end

#transform_keysObject

Returns the value of attribute transform_keys.



15
16
17
# File 'lib/abc_jsonapi.rb', line 15

def transform_keys
  @transform_keys
end