Module: ApiModel::ConfigurationMethods::ClassMethods

Defined in:
lib/api_model/configuration.rb

Instance Method Summary collapse

Instance Method Details

#api_config {|@_api_config| ... } ⇒ Object

Yields:

  • (@_api_config)


55
56
57
58
# File 'lib/api_model/configuration.rb', line 55

def api_config
  @_api_config = Configuration.from_inherited_config api_model_configuration
  yield @_api_config
end

#api_model_configurationObject



49
50
51
52
53
# File 'lib/api_model/configuration.rb', line 49

def api_model_configuration
  @_api_config || superclass.api_model_configuration
rescue
  @_api_config = Configuration.new
end

#reset_api_configurationObject



45
46
47
# File 'lib/api_model/configuration.rb', line 45

def reset_api_configuration
  @_api_config = nil
end