Class: ADIWG::Mdtranslator::Writers::Simple_html::Html_FeatureProperty
- Inherits:
-
Object
- Object
- ADIWG::Mdtranslator::Writers::Simple_html::Html_FeatureProperty
- Defined in:
- lib/adiwg/mdtranslator/writers/simple_html/sections/html_featureProperties.rb
Instance Method Summary collapse
-
#initialize(html) ⇒ Html_FeatureProperty
constructor
A new instance of Html_FeatureProperty.
- #writeHtml(hProperty) ⇒ Object
Constructor Details
#initialize(html) ⇒ Html_FeatureProperty
Returns a new instance of Html_FeatureProperty.
16 17 18 |
# File 'lib/adiwg/mdtranslator/writers/simple_html/sections/html_featureProperties.rb', line 16 def initialize(html) @html = html end |
Instance Method Details
#writeHtml(hProperty) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 |
# File 'lib/adiwg/mdtranslator/writers/simple_html/sections/html_featureProperties.rb', line 20 def writeHtml(hProperty) # classes used identifierClass = Html_Identifier.new(@html) # feature properties - name [] hProperty[:featureNames].each do |feature| @html.em('Feature Name: ') @html.text!(feature) @html.br end # feature properties - description unless hProperty[:description].nil? @html.em('Description: ') @html.div(:class => 'block') do @html.text!(hProperty[:description]) end end # feature properties - identifier [] {identifier} hProperty[:identifiers].each do |hIdentifier| @html.div do @html.div('Identifier', 'class' => 'h5') @html.div(:class => 'block') do identifierClass.writeHtml(hIdentifier) end end end # feature properties - feature scope {scopeCode} unless hProperty[:featureScope].nil? @html.em('Feature Scope Code: ') @html.text!(hProperty[:featureScope]) @html.br end # feature properties - acquisition method unless hProperty[:featureScope].nil? @html.em('Acquisition Method: ') @html.div(:class => 'block') do @html.text!(hProperty[:acquisitionMethod]) end end end |