Class: GrapeOAS::Exporter::Base::Paths
- Inherits:
-
Object
- Object
- GrapeOAS::Exporter::Base::Paths
- Defined in:
- lib/grape_oas/exporter/base/paths.rb
Overview
Base class for Paths exporters Contains common logic shared between OAS2 and OAS3
Direct Known Subclasses
Instance Method Summary collapse
- #build ⇒ Object
-
#initialize(source, ref_tracker = nil, **options) ⇒ Paths
constructor
A new instance of Paths.
Constructor Details
#initialize(source, ref_tracker = nil, **options) ⇒ Paths
Returns a new instance of Paths.
9 10 11 12 13 |
# File 'lib/grape_oas/exporter/base/paths.rb', line 9 def initialize(source, ref_tracker = nil, **) @source = source @ref_tracker = ref_tracker @options = end |
Instance Method Details
#build ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/grape_oas/exporter/base/paths.rb', line 15 def build if api?(@source) build_paths(@source) else build_path_item(@source) end end |