Sha256: a985c9d3291ed8722e9efced4901cc56fae1c0caa419cac02f5a2b2bd5584c83

Contents?: true

Size: 380 Bytes

Versions: 12

Compression:

Stored size: 380 Bytes

Contents

require 'riak/i18n'

module Riak
  module Util
    # Methods for doing i18n string lookup
    module Translation
      # The scope of i18n messages
      def i18n_scope
        :riak
      end

      # Provides the translation for a given internationalized message
      def t(message, options = {})
        I18n.t("#{i18n_scope}.#{message}", options)
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 2 rubygems

Version Path
riak-client-2.6.0 lib/riak/util/translation.rb
riak-client-2.5.0 lib/riak/util/translation.rb
riak-client-2.4.1 lib/riak/util/translation.rb
riak-client-2.4.0 lib/riak/util/translation.rb
riak-client-2.4.0.pre1 lib/riak/util/translation.rb
riak-client-2.3.2 lib/riak/util/translation.rb
riak-client-2.3.1 lib/riak/util/translation.rb
riak-client-2.3.0 lib/riak/util/translation.rb
riak-client-2.2.2 lib/riak/util/translation.rb
riak-client-2.2.1 lib/riak/util/translation.rb
riak-client-noenc-1.0.0 lib/riak/util/translation.rb
riak-client-2.2.0 lib/riak/util/translation.rb