Crate lingual

Source

Macros§

cfg_blocking
adds the cfg “blocking” feature to any item that is wrapped in this macro.
cfg_gen_blocking
generates the sync version of the function if given the async version of the function. it will tranverse the function and remove the async keyword and the .await keyword. and also add the blocking feature to the function.
cfg_non_blocking
Adds the cfg “default” feature any item that is wrapped in this macro will be added to the

Structs§

LangIter
An iterator over the variants of Lang
Translation
Encapsulates a translated text and its source and target languages.

Enums§

AccurateLang
The language codes supported by the API. It is also possible to use strings like “en” or “fr” instead of the enum variants but it is not recommended because it is not checked at compile time, therefore it is eliminated by default features. To enable this feature, add strings to the features list of the crate. get how many variants are there in the enum at compile time. This is list has languages that have high translation accuracy and are also part of DeepL’s supported languages. this list includes:
Lang
The language codes supported by the API. It is also possible to use strings like “en” or “fr” instead of the enum variants but it is not recommended because it is not checked at compile time, therefore it is eliminated by default features. To enable this feature, add strings to the features list of the crate. get how many variants are there in the enum at compile time.
TranslationError
Translator

Statics§

CLIENT

Type Aliases§

TranslationResult