Class: Rucoa::Rbs::ClassDefinitionMapper

Inherits:
ModuleDefinitionMapper show all
Defined in:
lib/rucoa/rbs/class_definition_mapper.rb

Instance Method Summary collapse

Methods inherited from ModuleDefinitionMapper

call, #initialize

Constructor Details

This class inherits a constructor from Rucoa::Rbs::ModuleDefinitionMapper

Instance Method Details

#callRucoa::Definitions::ClassDefinition

Examples:

supports ‘include`

definition_store = Rucoa::DefinitionStore.new
definition_store.bulk_add(Rucoa::DefinitionArchiver.load)
subject = definition_store.find_definition_by_qualified_name('Array')
expect(subject.included_module_qualified_names).to include('Enumerable')

Returns:



12
13
14
15
16
17
18
19
20
21
22
# File 'lib/rucoa/rbs/class_definition_mapper.rb', line 12

def call
  Definitions::ClassDefinition.new(
    description: description,
    extended_module_qualified_names: extended_module_qualified_names,
    included_module_qualified_names: included_module_qualified_names,
    location: location,
    prepended_module_qualified_names: prepended_module_qualified_names,
    qualified_name: qualified_name,
    super_class_qualified_name: super_class_qualified_name
  )
end