Class: Rucoa::Yard::DefinitionGenerators::MethodDefinitionGenerator
- Defined in:
- lib/rucoa/yard/definition_generators/method_definition_generator.rb
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from Rucoa::Yard::DefinitionGenerators::Base
Instance Method Details
#call ⇒ Object
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/rucoa/yard/definition_generators/method_definition_generator.rb', line 38 def call return [] unless @node.is_a?(Nodes::DefNode) [ Definitions::MethodDefinition.new( description: description, kind: @node.singleton? ? :singleton : :instance, location: location, method_name: @node.name, namespace: @node.namespace, types: return_types.map do |type| Types::MethodType.new( parameters_string: '', # TODO return_type: type ) end ) ] end |