Class: SwaggerModel::SwaggerV2::Included
- Inherits:
-
Object
- Object
- SwaggerModel::SwaggerV2::Included
- Defined in:
- lib/swagger_model/included.rb
Instance Attribute Summary collapse
-
#models ⇒ Object
Returns the value of attribute models.
Instance Method Summary collapse
-
#initialize(array) ⇒ Included
constructor
A new instance of Included.
- #models_to_swagger_hash(model) ⇒ Object
Constructor Details
#initialize(array) ⇒ Included
Returns a new instance of Included.
6 7 8 |
# File 'lib/swagger_model/included.rb', line 6 def initialize(array) @models = array.map { |e| Model.new(e) } end |
Instance Attribute Details
#models ⇒ Object
Returns the value of attribute models.
4 5 6 |
# File 'lib/swagger_model/included.rb', line 4 def models @models end |
Instance Method Details
#models_to_swagger_hash(model) ⇒ Object
10 11 12 13 14 |
# File 'lib/swagger_model/included.rb', line 10 def models_to_swagger_hash(model) @models.each do |e| e.to_swagger_hash(model) end end |