com.abbyy.mobile.rtr

## Interface IRecognitionCoreAPI

- All Superinterfaces:
    java.lang.AutoCloseable, TextCapture

      public interface IRecognitionCoreAPI
      extends java.lang.AutoCloseable, TextCapture

  Provides access to low-level single image core API functions for current thread. Should be used on the same thread on which it was created. Multiple objects can be created on different threads and used concurrently. All methods are synchronous (blocking) and should not be used on UI thread. For advanced users.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `IRecognitionCoreAPI.ExtendedSettings` Extended configuration settings.
    `static interface` | `IRecognitionCoreAPI.ProcessingSettings` Basic settings applicable to most methods
    `static class` | `IRecognitionCoreAPI.TextBlock` The `TextBlock` is a collection of lines of recognized text.
    `static interface` | `IRecognitionCoreAPI.TextRecognitionCallback` Callback for text recognition methods.
    `static interface` | `IRecognitionCoreAPI.TextRecognitionSettings` Settings for text recognition.
    `static class` | `IRecognitionCoreAPI.TranslationResult` Deprecated.
    `static class` | `IRecognitionCoreAPI.Warning` Warnings

    - ### Nested classes/interfaces inherited from interface com.abbyy.mobile.rtr.TextCapture

      `TextCapture.CaptureSceneType, TextCapture.CharInfo, TextCapture.TextLine, TextCapture.TextType`

  - ### Field Summary

    - ### Fields inherited from interface com.abbyy.mobile.rtr.TextCapture

      `CHAR_ATTRIBUTE_BOLD, CHAR_ATTRIBUTE_ITALIC, CHAR_ATTRIBUTE_SMALLCAPS, CHAR_ATTRIBUTE_STRIKETHROUGH, CHAR_ATTRIBUTE_SUPERSCRIPT, CHAR_ATTRIBUTE_UNCERTAIN, CHAR_ATTRIBUTE_UNDERLINED`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()` Release all resources.
    `IRecognitionCoreAPI.ExtendedSettings` | `getExtendedSettings()` Extended configuration settings.
    `IRecognitionCoreAPI.ProcessingSettings` | `getProcessingSettings()` Basic settings applicable to most methods
    `IRecognitionCoreAPI.TextRecognitionSettings` | `getTextRecognitionSettings()` Settings for text recognition.
    `IRecognitionCoreAPI.TextBlock[]` | `recognizeText(android.graphics.Bitmap image, IRecognitionCoreAPI.TextRecognitionCallback callback)` Recognize text on a still image.
    `void` | `setTranslationDictionary(java.lang.String dictionaryName)` Deprecated. Sets the name of the translation dictionary. By default, no translation dictionary is used. Translation dictionaries should be put in the 'assets\translation' folder.
    `IRecognitionCoreAPI.TranslationResult` | `translate(java.lang.String text)` Deprecated. Translate the input string. Non-translatable substrings are returned as is.

- - ### Method Detail

    - #### recognizeText

          IRecognitionCoreAPI.TextBlock[] recognizeText(android.graphics.Bitmap image,
                                                        IRecognitionCoreAPI.TextRecognitionCallback callback)

      Recognize text on a still image.

      see getTextRecognitionSettings below

      Parameters:
        `image` - Image to recognize.
        `callback` - Implementation of the `TextRecognitionCallback` interface. Is called during the recognition to track the recognition progress and interrupt processing if required.
      Returns:
        an array of `TextBlock` objects.

    - #### translate

          @Deprecated
          IRecognitionCoreAPI.TranslationResult translate(java.lang.String text)
                                                                throws Engine.LicenseException,
                                                                       java.io.IOException

      Deprecated. Translate the input string. Non-translatable substrings are returned as is.
      Parameters:
        `text` - Text to translate.
      Returns:
        a translated string.
      Throws:
        `Engine.LicenseException` - if license exception occurs
        `java.io.IOException` - if IO exception occurs

    - #### setTranslationDictionary

          @Deprecated
          void setTranslationDictionary(java.lang.String dictionaryName)

      Deprecated. Sets the name of the translation dictionary.

      By default, no translation dictionary is used. Translation dictionaries should be put in the 'assets\translation' folder.

      Parameters:
        `dictionaryName` - the name of the translation dictionary file without extension

    - #### close

          void close()

      Release all resources.
      Specified by:
        `close` in interface `java.lang.AutoCloseable`

    - #### getProcessingSettings

          IRecognitionCoreAPI.ProcessingSettings getProcessingSettings()

      Basic settings applicable to most methods
      Returns:
        processing settings

    - #### getTextRecognitionSettings

          IRecognitionCoreAPI.TextRecognitionSettings getTextRecognitionSettings()

      Settings for text recognition.
      Returns:
        text recognition settings

    - #### getExtendedSettings

          IRecognitionCoreAPI.ExtendedSettings getExtendedSettings()

      Extended configuration settings. Settings for advanced users. Not used in typical scenarios
      Returns:
        extended service configuration settings