module FastGettext

Modifications wrapped inside FastGettext namespace to reduce conflic

Provides FastGettext::Iconv.iconv which normally is provided through Ruby/GLib(1) functions. This library is required for 'gettext'. If you require 'gettext/iconv', it tries to call Ruby/GLib function when it doesn't find original Iconv class(iconv.so) it adds a pseudo class.

One-click Ruby Installer for Win32 hadn’t had iconv and there hadn’t been a way to install iconv.so itself for Win32. And JRuby hadn’t had Iconv. I’ve not checked them currently, but if they’ve supported iconv now, we don’t need this anymore…

(1) Ruby/GLib is a module which is provided from Ruby-GNOME2 Project. You can get binaries for Win32(One-Click Ruby Installer). <URL: ruby-gnome2.sourceforge.jp/>

Constants

Iconv
LOCALE_REX
NAMESPACE_SEPARATOR
VERSION

Public Instance Methods

add_text_domain(name,options) click to toggle source
# File lib/fast_gettext.rb, line 27
def add_text_domain(name,options)
  translation_repositories[name] = TranslationRepository.build(name,options)
end
locale_path() click to toggle source

some repositories know where to store their locales

# File lib/fast_gettext.rb, line 32
def locale_path
  translation_repositories[text_domain].instance_variable_get(:@options)[:path]
end