class String

Public Instance Methods

tr8n_translated() click to toggle source
# File lib/tr8n_core/ext/string.rb, line 46
def tr8n_translated
  return self if frozen?
  @tr8n_translated = true
  self
end
tr8n_translated?() click to toggle source
# File lib/tr8n_core/ext/string.rb, line 52
def tr8n_translated?
  @tr8n_translated
end
translate(desc = '', tokens = {}, options = {}) click to toggle source
# File lib/tr8n_core/ext/string.rb, line 34
def translate(desc = '', tokens = {}, options = {})
  Tr8n.session.target_language.translate(
      Tr8n::Utils.normalize_tr_params(self, desc, tokens, options)
  )
end
trl(desc = '', tokens = {}, options = {}) click to toggle source
# File lib/tr8n_core/ext/string.rb, line 40
def trl(desc = '', tokens = {}, options = {})
  Tr8n.session.target_language.translate(
      Tr8n::Utils.normalize_tr_params(self, desc, tokens, options.merge(:skip_decorations => true))
  )
end