Class: ADIWG::Mdtranslator::Writers::Fgdc::GeographicResolution
- Inherits:
-
Object
- Object
- ADIWG::Mdtranslator::Writers::Fgdc::GeographicResolution
- Defined in:
- lib/adiwg/mdtranslator/writers/fgdc/classes/class_geographicResolution.rb
Instance Method Summary collapse
-
#initialize(xml, hResponseObj) ⇒ GeographicResolution
constructor
A new instance of GeographicResolution.
- #writeXML(hGeoRes, inContext = nil) ⇒ Object
Constructor Details
#initialize(xml, hResponseObj) ⇒ GeographicResolution
Returns a new instance of GeographicResolution.
17 18 19 20 21 |
# File 'lib/adiwg/mdtranslator/writers/fgdc/classes/class_geographicResolution.rb', line 17 def initialize(xml, hResponseObj) @xml = xml @hResponseObj = hResponseObj @NameSpace = ADIWG::Mdtranslator::Writers::Fgdc end |
Instance Method Details
#writeXML(hGeoRes, inContext = nil) ⇒ Object
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/writers/fgdc/classes/class_geographicResolution.rb', line 23 def writeXML(hGeoRes, inContext = nil) # horizontal reference 4.1.1 (geograph) - geographic resolution # geographic resolution 4.1.1.1 (latres) - latitude resolution (required) unless hGeoRes[:latitudeResolution].nil? @xml.tag!('latres', hGeoRes[:latitudeResolution]).to_s end if hGeoRes[:latitudeResolution].nil? @NameSpace.issueWarning(160, 'latres') end # geographic resolution 4.1.1.2 (longres) - longitude resolution (required) unless hGeoRes[:longitudeResolution].nil? @xml.tag!('longres', hGeoRes[:longitudeResolution]).to_s end if hGeoRes[:longitudeResolution].nil? @NameSpace.issueWarning(161, 'longres') end # geographic resolution 4.1.1.3 (geogunit) - longitude resolution (required) unless hGeoRes[:unitOfMeasure].nil? @xml.tag!('geogunit', hGeoRes[:unitOfMeasure]) end if hGeoRes[:unitOfMeasure].nil? @NameSpace.issueWarning(162, 'geogunit') end end |