Module: PragmaticSegmenter::Languages
- Defined in:
- lib/pragmatic_segmenter/languages.rb,
lib/pragmatic_segmenter/languages/urdu.rb,
lib/pragmatic_segmenter/languages/dutch.rb,
lib/pragmatic_segmenter/languages/greek.rb,
lib/pragmatic_segmenter/languages/hindi.rb,
lib/pragmatic_segmenter/languages/arabic.rb,
lib/pragmatic_segmenter/languages/common.rb,
lib/pragmatic_segmenter/languages/danish.rb,
lib/pragmatic_segmenter/languages/french.rb,
lib/pragmatic_segmenter/languages/kazakh.rb,
lib/pragmatic_segmenter/languages/polish.rb,
lib/pragmatic_segmenter/languages/amharic.rb,
lib/pragmatic_segmenter/languages/burmese.rb,
lib/pragmatic_segmenter/languages/chinese.rb,
lib/pragmatic_segmenter/languages/deutsch.rb,
lib/pragmatic_segmenter/languages/english.rb,
lib/pragmatic_segmenter/languages/italian.rb,
lib/pragmatic_segmenter/languages/persian.rb,
lib/pragmatic_segmenter/languages/russian.rb,
lib/pragmatic_segmenter/languages/spanish.rb,
lib/pragmatic_segmenter/languages/armenian.rb,
lib/pragmatic_segmenter/languages/japanese.rb,
lib/pragmatic_segmenter/languages/bulgarian.rb,
lib/pragmatic_segmenter/languages/common/numbers.rb,
lib/pragmatic_segmenter/languages/common/ellipsis.rb
Defined Under Namespace
Modules: Amharic, Arabic, Armenian, Bulgarian, Burmese, Chinese, Common, Danish, Deutsch, Dutch, English, French, Greek, Hindi, Italian, Japanese, Kazakh, Persian, Polish, Russian, Spanish, Urdu
Constant Summary collapse
- LANGUAGE_CODES =
{ 'en' => English, 'bg' => Bulgarian, 'de' => Deutsch, 'es' => Spanish, 'fr' => French, 'it' => Italian, 'ja' => Japanese, 'el' => Greek, 'ru' => Russian, 'ar' => Arabic, 'am' => Amharic, 'hi' => Hindi, 'hy' => Armenian, 'fa' => Persian, 'my' => Burmese, 'ur' => Urdu, 'nl' => Dutch, 'pl' => Polish, 'zh' => Chinese, 'da' => Danish, 'kk' => Kazakh }
Class Method Summary collapse
Class Method Details
.get_language_by_code(code) ⇒ Object
57 58 59 |
# File 'lib/pragmatic_segmenter/languages.rb', line 57 def self.get_language_by_code(code) LANGUAGE_CODES[code] || Common end |