Class: TwitterCldr::Localized::LocalizedSymbol

Inherits:
LocalizedObject show all
Defined in:
lib/twitter_cldr/localized/localized_symbol.rb

Instance Attribute Summary

Attributes inherited from LocalizedObject

#base_obj, #formatter, #locale

Instance Method Summary collapse

Methods inherited from LocalizedObject

#initialize, localize

Constructor Details

This class inherits a constructor from TwitterCldr::Localized::LocalizedObject

Instance Method Details

#as_language_codeObject



10
11
12
# File 'lib/twitter_cldr/localized/localized_symbol.rb', line 10

def as_language_code
  TwitterCldr::Shared::Languages.from_code_for_locale(@base_obj, @locale)
end

#as_localeObject



14
15
16
# File 'lib/twitter_cldr/localized/localized_symbol.rb', line 14

def as_locale
  TwitterCldr::Shared::Locale.parse(@base_obj.to_s)
end

#as_territoryObject



18
19
20
# File 'lib/twitter_cldr/localized/localized_symbol.rb', line 18

def as_territory
  TwitterCldr::Shared::Territories::from_territory_code_for_locale(@base_obj, @locale)
end

#formatter_constObject



26
27
28
# File 'lib/twitter_cldr/localized/localized_symbol.rb', line 26

def formatter_const
  nil
end

#is_rtl?Boolean

Returns:

  • (Boolean)


22
23
24
# File 'lib/twitter_cldr/localized/localized_symbol.rb', line 22

def is_rtl?
  TwitterCldr::Shared::Languages.is_rtl?(@base_obj)
end