Class: Dryer::Clients::Gems::ApiDescriptionFiles::Create
- Inherits:
-
Services::SimpleService
- Object
- Services::SimpleService
- Dryer::Clients::Gems::ApiDescriptionFiles::Create
- Defined in:
- lib/dryer/clients/gems/api_description_files/create.rb
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(gem_module_name:, api_description:, output_directory:) ⇒ Create
constructor
A new instance of Create.
Constructor Details
#initialize(gem_module_name:, api_description:, output_directory:) ⇒ Create
Returns a new instance of Create.
11 12 13 14 15 16 17 18 19 |
# File 'lib/dryer/clients/gems/api_description_files/create.rb', line 11 def initialize( gem_module_name:, api_description:, output_directory: ) @gem_module_name = gem_module_name @api_description = api_description @output_directory = output_directory end |
Instance Method Details
#call ⇒ Object
21 22 23 24 25 26 |
# File 'lib/dryer/clients/gems/api_description_files/create.rb', line 21 def call { path: "#{output_directory}/api_description.rb", contents: api_description_file_contents(stringify_class_names(api_description)) } end |