Class: ApiMaker::ModelContentGeneratorService

Inherits:
ApplicationService
  • Object
show all
Defined in:
app/services/api_maker/model_content_generator_service.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from ApplicationService

#api_maker_json

Constructor Details

#initialize(resource:) ⇒ ModelContentGeneratorService

Returns a new instance of ModelContentGeneratorService.



6
7
8
# File 'app/services/api_maker/model_content_generator_service.rb', line 6

def initialize(resource:)
  @resource = resource
end

Instance Attribute Details

#resourceObject (readonly)

Returns the value of attribute resource.



2
3
4
# File 'app/services/api_maker/model_content_generator_service.rb', line 2

def resource
  @resource
end

Instance Method Details

#performObject



10
11
12
# File 'app/services/api_maker/model_content_generator_service.rb', line 10

def perform
  succeed! model_content
end