Class: ScaffoldParser::Scaffolders::XSD::Parser::Handlers::ElementRef

Inherits:
Object
  • Object
show all
Defined in:
lib/scaffold_parser/scaffolders/xsd/parser/handlers/element_ref.rb

Instance Method Summary collapse

Constructor Details

#initialize(source) ⇒ ElementRef

Returns a new instance of ElementRef.



7
8
9
# File 'lib/scaffold_parser/scaffolders/xsd/parser/handlers/element_ref.rb', line 7

def initialize(source)
  @source = source
end

Instance Method Details

#to_submodel_method(ref_map) ⇒ Object



11
12
13
14
15
# File 'lib/scaffold_parser/scaffolders/xsd/parser/handlers/element_ref.rb', line 11

def to_submodel_method(ref_map)
  name = ref_map[@source.ref].split(':').map(&:classify).join('::')

  SubmodelMethod.new(@source, name)
end