Module: OpenAPIParser::Parser::Value

Included in:
Core
Defined in:
lib/openapi_parser/concerns/parser/value.rb

Instance Method Summary collapse

Instance Method Details

#_openapi_attr_valuesObject



2
3
4
# File 'lib/openapi_parser/concerns/parser/value.rb', line 2

def _openapi_attr_values
  @_openapi_attr_values ||= {}
end

#openapi_attr_value(name, options = {}) ⇒ Object



10
11
12
13
# File 'lib/openapi_parser/concerns/parser/value.rb', line 10

def openapi_attr_value(name, options = {})
  target_klass.send(:attr_reader, name)
  _openapi_attr_values[name] = OpenAPIParser::SchemaLoader::ValuesLoader.new(name, options)
end

#openapi_attr_values(*names) ⇒ Object



6
7
8
# File 'lib/openapi_parser/concerns/parser/value.rb', line 6

def openapi_attr_values(*names)
  names.each { |name| openapi_attr_value(name) }
end