Exception: I18n::MissingTranslationData
- Inherits:
-
ArgumentError
- Object
- ArgumentError
- ArgumentError
- I18n::MissingTranslationData
- Defined in:
- lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb
Instance Attribute Summary collapse
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#locale ⇒ Object
readonly
Returns the value of attribute locale.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(locale, key, options) ⇒ MissingTranslationData
constructor
A new instance of MissingTranslationData.
Constructor Details
#initialize(locale, key, options) ⇒ MissingTranslationData
Returns a new instance of MissingTranslationData.
14 15 16 17 18 19 |
# File 'lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb', line 14 def initialize(locale, key, ) @key, @locale, @options = key, locale, keys = I18n.send(:normalize_translation_keys, locale, key, [:scope]) keys << 'no key' if keys.size < 2 super "translation missing: #{keys.join(', ')}" end |
Instance Attribute Details
#key ⇒ Object (readonly)
Returns the value of attribute key.
13 14 15 |
# File 'lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb', line 13 def key @key end |
#locale ⇒ Object (readonly)
Returns the value of attribute locale.
13 14 15 |
# File 'lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb', line 13 def locale @locale end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
13 14 15 |
# File 'lib/gems/activesupport-2.2.2/lib/active_support/vendor/i18n-0.0.1/i18n/exceptions.rb', line 13 def @options end |