Package org.mozilla.geckoview
Class TranslationsController.TranslationsException
- All Implemented Interfaces:
Serializable
- Enclosing class:
- TranslationsController
An exception to be used when there is an issue retrieving or sending information to the
translations toolkit engine.
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic @interface
Translation exception error codes. -
Field Summary
Modifier and TypeFieldDescriptionfinal int
TranslationsController.TranslationsException.Code
that provides more information about this exception.static final int
Could not load language options error.static final int
Generic could not restore the page after a translation error.static final int
Generic could not compete a translation error.static final int
Translations engine does not work on the device architecture.static final int
The language is not supported for translation.static final int
Could not delete the language model.static final int
Could not download the language model.static final int
Could not retrieve information on the language model.static final int
A download is required and the translate request specified do not download.static final int
A language is required for language scoped requests.static final int
Default error for unexpected issues. -
Constructor Summary
-
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Field Details
-
ERROR_UNKNOWN
public static final int ERROR_UNKNOWNDefault error for unexpected issues.- See Also:
-
ERROR_ENGINE_NOT_SUPPORTED
public static final int ERROR_ENGINE_NOT_SUPPORTEDTranslations engine does not work on the device architecture.- See Also:
-
ERROR_COULD_NOT_TRANSLATE
public static final int ERROR_COULD_NOT_TRANSLATEGeneric could not compete a translation error.- See Also:
-
ERROR_COULD_NOT_RESTORE
public static final int ERROR_COULD_NOT_RESTOREGeneric could not restore the page after a translation error.- See Also:
-
ERROR_COULD_NOT_LOAD_LANGUAGES
public static final int ERROR_COULD_NOT_LOAD_LANGUAGESCould not load language options error.- See Also:
-
ERROR_LANGUAGE_NOT_SUPPORTED
public static final int ERROR_LANGUAGE_NOT_SUPPORTEDThe language is not supported for translation.- See Also:
-
ERROR_MODEL_COULD_NOT_RETRIEVE
public static final int ERROR_MODEL_COULD_NOT_RETRIEVECould not retrieve information on the language model.- See Also:
-
ERROR_MODEL_COULD_NOT_DELETE
public static final int ERROR_MODEL_COULD_NOT_DELETECould not delete the language model.- See Also:
-
ERROR_MODEL_COULD_NOT_DOWNLOAD
public static final int ERROR_MODEL_COULD_NOT_DOWNLOADCould not download the language model.- See Also:
-
ERROR_MODEL_LANGUAGE_REQUIRED
public static final int ERROR_MODEL_LANGUAGE_REQUIREDA language is required for language scoped requests.- See Also:
-
ERROR_MODEL_DOWNLOAD_REQUIRED
public static final int ERROR_MODEL_DOWNLOAD_REQUIREDA download is required and the translate request specified do not download.- See Also:
-
code
public final int codeTranslationsController.TranslationsException.Code
that provides more information about this exception.
-
-
Constructor Details
-
TranslationsException
public TranslationsException(int code) Construct a [TranslationsException]- Parameters:
code
- Error code the given exception corresponds to.
-
-
Method Details