Class: Stepmod::Utils::Converters::ExtDescription

Inherits:
Base
  • Object
show all
Defined in:
lib/stepmod/utils/converters/ext_description.rb

Constant Summary

Constants inherited from Base

Base::PREFIXES_REGEX

Instance Method Summary collapse

Methods inherited from Base

#treat_children

Instance Method Details

#convert(node, state = {}) ⇒ Object



5
6
7
8
9
10
11
12
13
14
# File 'lib/stepmod/utils/converters/ext_description.rb', line 5

def convert(node, state = {})
  state = state.merge(schema_name: node["linkend"], non_flanking_whitesapce: true)
  child_text = treat_children(node, state).strip

  <<~TEMPLATE
    (*"#{node['linkend']}"
    #{child_text}
    *)
  TEMPLATE
end