Method: I18n::Inflector::API_Strict#aliases

Defined in:
lib/i18n-inflector/api_strict.rb

#aliases(kind) ⇒ Hash #aliases(kind, locale) ⇒ Hash

Gets inflection aliases belonging to a strict kind and their pointers.

Overloads:

  • #aliases(kind) ⇒ Hash

    Gets inflection aliases (and their pointers) of the given kind and the current locale.

    Parameters:

    • kind (Symbol, String)

      the kind of aliases to get

    Returns:

    • (Hash)

      the Hash containing available inflection aliases

  • #aliases(kind, locale) ⇒ Hash

    Gets inflection aliases (and their pointers) of the given kind and locale.

    Parameters:

    • kind (Symbol, String)

      the kind of aliases to get

    • locale (Symbol)

      the locale to use

    Returns:

    • (Hash)

      the Hash containing available inflection aliases

Returns:

  • (Hash)

    the Hash containing available inflection aliases (alias => target)

Raises:


564
565
566
# File 'lib/i18n-inflector/api_strict.rb', line 564

def aliases(kind=nil, locale=nil)
  each_alias(kind, locale).to_h
end