Class: IsoDoc::MnRequirementsI18n

Inherits:
I18n
  • Object
show all
Defined in:
lib/isodoc/i18n.rb

Instance Method Summary collapse

Instance Method Details

#load_yaml1(lang, script) ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
# File 'lib/isodoc/i18n.rb', line 6

def load_yaml1(lang, script)
  case lang
  when "en", "fr", "ru", "de", "es", "ar"
    load_yaml2(lang)
  when "zh"
    if script == "Hans" then load_yaml2("zh-Hans")
    else load_yaml2("en")
    end
  else load_yaml2("en")
  end
end

#load_yaml2(str) ⇒ Object



18
19
20
21
# File 'lib/isodoc/i18n.rb', line 18

def load_yaml2(str)
  YAML.load_file(File.join(File.dirname(__FILE__),
                           "../isodoc-yaml/i18n-#{str}.yaml"))
end