Method: I18n::Inflector::API_Strict#each_token
- Defined in:
- lib/i18n-inflector/api_strict.rb
permalink #each_token(kind) ⇒ LazyHashEnumerator #each_token(kind, locale) ⇒ LazyHashEnumerator
Note:
You cannot deduce where aliases are pointing to, since the information about a target is replaced by the description. To get targets use the #raw_tokens method. To simply list aliases and their targets use the #aliases method.
Iterates through available inflection tokens belonging to a strict kind and their descriptions.
394 395 396 397 |
# File 'lib/i18n-inflector/api_strict.rb', line 394 def each_token(kind=nil, locale=nil, &block) kind = kind.to_s.empty? ? nil : kind.to_sym data_safe(locale).each_token(kind, &block) end |