Class: Grape::Validations::ParamsDocumentation::TypeCache

Inherits:
Util::Cache
  • Object
show all
Defined in:
lib/grape/validations/params_documentation.rb

Instance Attribute Summary

Attributes inherited from Util::Cache

#cache

Instance Method Summary collapse

Constructor Details

#initializeTypeCache

Returns a new instance of TypeCache.



41
42
43
44
45
46
# File 'lib/grape/validations/params_documentation.rb', line 41

def initialize
  super
  @cache = Hash.new do |h, type|
    h[type] = type.to_s
  end
end