Class TranslationsController.TranslationsException

Object
Throwable
Exception
org.mozilla.geckoview.TranslationsController.TranslationsException
All Implemented Interfaces:
Serializable
Enclosing class:
TranslationsController

public static class TranslationsController.TranslationsException extends Exception
An exception to be used when there is an issue retrieving or sending information to the translations toolkit engine.
See Also:
  • Field Details

    • ERROR_UNKNOWN

      public static final int ERROR_UNKNOWN
      Default error for unexpected issues.
      See Also:
    • ERROR_ENGINE_NOT_SUPPORTED

      public static final int ERROR_ENGINE_NOT_SUPPORTED
      Translations engine does not work on the device architecture.
      See Also:
    • ERROR_COULD_NOT_TRANSLATE

      public static final int ERROR_COULD_NOT_TRANSLATE
      Generic could not compete a translation error.
      See Also:
    • ERROR_COULD_NOT_RESTORE

      public static final int ERROR_COULD_NOT_RESTORE
      Generic could not restore the page after a translation error.
      See Also:
    • ERROR_COULD_NOT_LOAD_LANGUAGES

      public static final int ERROR_COULD_NOT_LOAD_LANGUAGES
      Could not load language options error.
      See Also:
    • ERROR_LANGUAGE_NOT_SUPPORTED

      public static final int ERROR_LANGUAGE_NOT_SUPPORTED
      The language is not supported for translation.
      See Also:
    • ERROR_MODEL_COULD_NOT_RETRIEVE

      public static final int ERROR_MODEL_COULD_NOT_RETRIEVE
      Could not retrieve information on the language model.
      See Also:
    • ERROR_MODEL_COULD_NOT_DELETE

      public static final int ERROR_MODEL_COULD_NOT_DELETE
      Could not delete the language model.
      See Also:
    • ERROR_MODEL_COULD_NOT_DOWNLOAD

      public static final int ERROR_MODEL_COULD_NOT_DOWNLOAD
      Could not download the language model.
      See Also:
    • ERROR_MODEL_LANGUAGE_REQUIRED

      public static final int ERROR_MODEL_LANGUAGE_REQUIRED
      A language is required for language scoped requests.
      See Also:
    • ERROR_MODEL_DOWNLOAD_REQUIRED

      public static final int ERROR_MODEL_DOWNLOAD_REQUIRED
      A download is required and the translate request specified do not download.
      See Also:
    • code

      public final int code
      TranslationsController.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