Sha256: d3ef325f814d73225381475ff8a72a7522550b6f1fa226be745f5d1042e7ef32

Contents?: true

Size: 1.34 KB

Versions: 15

Compression:

Stored size: 1.34 KB

Contents

# ISO <<Class>> MD_RepresentativeFraction
# 19115-1 writer output in XML

# History:
#  Stan Smith 2019-03-21 original script

require_relative '../iso19115_1_writer'

module ADIWG
   module Mdtranslator
      module Writers
         module Iso19115_1

            class MD_RepresentativeFraction

               def initialize(xml, hResponseObj)
                  @xml = xml
                  @hResponseObj = hResponseObj
                  @NameSpace = ADIWG::Mdtranslator::Writers::Iso19115_1
               end

               def writeXML(denominator, inContext = nil)

                  outContext = 'scale factor'
                  outContext = inContext + ' scale factor' unless inContext.nil?

                  @xml.tag!('mri:MD_RepresentativeFraction') do

                     # representative fraction - denominator
                     unless denominator.nil?
                        @xml.tag!('mri:denominator') do
                           @xml.tag!('gco:Integer', denominator)
                        end
                     end
                     if denominator.nil?
                        @NameSpace.issueWarning(120, 'mri:denominator', outContext)
                     end

                  end # gmd:MD_RepresentativeFraction tag
               end # writeXML
            end # MD_RepresentativeFraction class

         end
      end
   end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
adiwg-mdtranslator-2.18.2 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.1 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc9 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc8 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc7 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc6 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc5 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc4 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc3 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc2 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.18.0rc1 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.17.1 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.16.1 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb
adiwg-mdtranslator-2.15.0 lib/adiwg/mdtranslator/writers/iso19115_1/classes/class_fraction.rb