Class: DoctorSwagger::RootSwaggerDoc
- Inherits:
-
SwaggerDoc
- Object
- SwaggerDoc
- DoctorSwagger::RootSwaggerDoc
- Defined in:
- lib/doctor_swagger/root_swagger_doc.rb
Instance Method Summary collapse
-
#initialize(base_path_extension, options = {}, &block) ⇒ RootSwaggerDoc
constructor
A new instance of RootSwaggerDoc.
Methods inherited from SwaggerDoc
Constructor Details
#initialize(base_path_extension, options = {}, &block) ⇒ RootSwaggerDoc
Returns a new instance of RootSwaggerDoc.
4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/doctor_swagger/root_swagger_doc.rb', line 4 def initialize(base_path_extension, = {}, &block) [:swagger_version] ||= DoctorSwagger.swagger_version [:api_version] ||= DoctorSwagger.api_version [:base_path] ||= DoctorSwagger.base_path @swagger_version = [:swagger_version] @api_version = [:api_version] @base_path = try_call([:base_path]) @base_path += base_path_extension @endpoints = [] instance_eval(&block) end |