dhwani.mappings package

Submodules

dhwani.mappings.utils module

dhwani.mappings.utils.is_supported(src_lang_code: str, dest_lang_code: str)

Checks if the given pair of languages are supported for conversion.

Parameters:
  • src_lang_code (str) – ISO 639-3 code of the source language.
  • dest_lang_code – ISO 639-3 code of the destination language.
Returns:

Boolean value for whether the source and destination language pair is supported.

Return type:

Boolean

dhwani.mappings.utils.print_current_support()

Prints the currently supported mappings of supported languages.

dhwani.mappings.utils.get_lang_mappings(src_lang_code: str, dest_lang_code: str)

Returns the mappings from source language to destination language as a list.

Parameters:
  • src_lang_code (str) – ISO 639-3 code of the source language.
  • dest_lang_code – ISO 639-3 code of the destination language.
Returns:

List with each element as a dictionary, where keys need to be replaced by values.

Return type:

List.

dhwani.mappings.utils.get_supported_conversions()

Returns all the currently supported conversions.

Returns:Returns the currently supported conversins in a dictionary whose keys are ISO 639-3 codes of source languages and the values are list containing the ISO 639-3 codes of destination languages.
Return type:Dictionary.

Module contents