Class: Gapic::Generators::BaseGenerator

Inherits:
Object
  • Object
show all
Defined in:
lib/gapic/generators/base_generator.rb

Overview

The generator orchestrates the rendering of templates.

Direct Known Subclasses

DefaultGenerator

Instance Method Summary collapse

Constructor Details

#initialize(api) ⇒ BaseGenerator

Initializes the generator.

Parameters:



30
31
32
# File 'lib/gapic/generators/base_generator.rb', line 30

def initialize api
  @api = api
end

Instance Method Details

#generateArray< Google::Protobuf::Compiler::CodeGeneratorResponse::File>

Generates all the files for the API.

Returns:

  • (Array< Google::Protobuf::Compiler::CodeGeneratorResponse::File>)

    The files that were generated for the API.



39
40
41
# File 'lib/gapic/generators/base_generator.rb', line 39

def generate
  raise "must implement"
end