Class: R2OAS::Schema::V3::Components::ObjectGenerator
- Inherits:
-
BaseGenerator
- Object
- Base
- Base
- Base
- BaseGenerator
- R2OAS::Schema::V3::Components::ObjectGenerator
- Defined in:
- lib/r2-oas/schema/v3/generator/components/object_generator.rb
Direct Known Subclasses
Constant Summary
Constants inherited from Base
Base::SUPPORT_COMPONENTS_OBJECTS
Instance Method Summary collapse
- #generate_docs ⇒ Object
-
#initialize(schema_data = {}, options = {}) ⇒ ObjectGenerator
constructor
A new instance of ObjectGenerator.
Methods included from R2OAS::Sortable
Methods inherited from Base
Constructor Details
#initialize(schema_data = {}, options = {}) ⇒ ObjectGenerator
Returns a new instance of ObjectGenerator.
13 14 15 16 17 18 19 20 |
# File 'lib/r2-oas/schema/v3/generator/components/object_generator.rb', line 13 def initialize(schema_data = {}, = {}) super(.except(:middle_category)) @major_category = 'components' @middle_category = [:middle_category] sorted_schema_data = deep_sort(schema_data, @middle_category) @components_objects = sorted_schema_data[@middle_category] @glob_schema_paths = create_glob_components_objects_paths end |
Instance Method Details
#generate_docs ⇒ Object
22 23 24 25 |
# File 'lib/r2-oas/schema/v3/generator/components/object_generator.rb', line 22 def generate_docs logger.info ' <From routes data>' generate_docs_from_routes_data end |