Module: Adiwg_VerticalElement
- Defined in:
- lib/adiwg/mdtranslator/readers/adiwgJson/modules_0.9.0/module_verticalElement.rb
Overview
History: Stan Smith 2013-11-18 original script Stan Smith 2013-12-11 modified to handle single vertical element
Class Method Summary collapse
Class Method Details
.unpack(hVertElement) ⇒ Object
10 11 12 13 14 15 16 17 18 19 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 |
# File 'lib/adiwg/mdtranslator/readers/adiwgJson/modules_0.9.0/module_verticalElement.rb', line 10 def self.unpack(hVertElement) # instance classes needed in script intMetadataClass = InternalMetadata.new intVertEle = intMetadataClass.newVerticalElement # vertical element - minimum value if hVertElement.has_key?('minimumValue') s = hVertElement['minimumValue'] if s != '' intVertEle[:minValue] = s end end # vertical element - maximum value if hVertElement.has_key?('maximumValue') s = hVertElement['maximumValue'] if s != '' intVertEle[:maxValue] = s end end # vertical element - vertical crs title attribute if hVertElement.has_key?('verticalCRSTitle') s = hVertElement['verticalCRSTitle'] if s != '' intVertEle[:crsTitle] = s end end # vertical element - vertical crs link attribute if hVertElement.has_key?('verticalCRSUri') s = hVertElement['verticalCRSUri'] if s != '' intVertEle[:crsURI] = s end end return intVertEle end |