Module: Riak::Util::Translation

Included in:
Riak, BackwardsClockError, Bucket, Client, Client::HTTPBackend, Client::Node, Client::ProtobuffsBackend, Cluster, Conflict, Counter, FailedRequest, Link, MapReduce, MapReduce::FilterBuilder, MapReduce::Phase, Multiget, Node, Node::Console, RContent, RObject, RObject, SecondaryIndex, Serializers, Multipart::StreamParser, WalkSpec, WalkSpec
Defined in:
lib/riak/util/translation.rb

Overview

Methods for doing i18n string lookup

Instance Method Summary (collapse)

Instance Method Details

- (Object) i18n_scope

The scope of i18n messages



8
9
10
# File 'lib/riak/util/translation.rb', line 8

def i18n_scope
  :riak
end

- (Object) t(message, options = {})

Provides the translation for a given internationalized message



13
14
15
# File 'lib/riak/util/translation.rb', line 13

def t(message, options={})
  I18n.t("#{i18n_scope}.#{message}", options)
end