com.comtrade.ecm.engine.i18n.engine

## Class TextManagerEngine

- java.lang.Object
- - com.comtrade.ecm.engine.i18n.engine.TextManagerEngine

- All Implemented Interfaces:
    TextManager, EcmService

      public class TextManagerEngine
      extends java.lang.Object

  An object that performs localization process

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TextManagerEngine()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addListener(TextManagerListener listener)` Adds a LocalizationManager listeners
    `java.lang.String` | `getString(java.lang.String key, java.util.Locale locale)` Returns localized text for a given key and given locale
    `java.lang.String` | `getString(java.lang.String defaultBundleFamilyName, java.lang.String key, java.util.Locale locale)` Vraća lokalizovanu vrednost za traženi key i locale
    `void` | `registerBundle(java.lang.String bundleFamilyName)` Registers a specific bundle (identified by its filename)
    `void` | `registerClassBundle(java.lang.Class<?> clazz)` Registers a specific bundle (identified by its class)
    `void` | `removeListener(TextManagerListener listener)` Removes a LocalizationManager listeners
    `void` | `setForceToLatin(boolean forceToLatin)` Instructs TextManager to force (or not to force) conversion to latin alphabet
    `void` | `unregisterBundle(java.lang.String bundleFamilyName)` Removes a specific bundle (identified by its filename)
    `void` | `unregisterClassBundle(java.lang.Class<?> clazz)` Removes a specific bundle (identified by its class)

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TextManagerEngine

          public TextManagerEngine()

  - ### Method Detail

    - #### getString

          public java.lang.String getString(java.lang.String key,
                                            java.util.Locale locale)

      Returns localized text for a given key and given locale
      Parameters:
        `key` - Internationalized value for which we want a localized version
        `locale` - Locale used for localization
      Returns:
        Localized text for a given key and locale

    - #### getString

          public java.lang.String getString(java.lang.String defaultBundleFamilyName,
                                            java.lang.String key,
                                            java.util.Locale locale)

      Vraća lokalizovanu vrednost za traženi key i locale
      Parameters:
        `key` - Internationalized value for which we want a localized version
        `locale` - Locale used for localization
        `defaultBundleFamilyName` - `ResourceBundle` which should be primarily used for localization
      Returns:
        Localized text for a given key and locale

    - #### setForceToLatin

          public void setForceToLatin(boolean forceToLatin)

      Description copied from interface: `TextManager`
      Instructs TextManager to force (or not to force) conversion to latin alphabet
      Parameters:
        `forceToLatin` - Whether we should force transformation to latin characters

    - #### addListener

          public void addListener(TextManagerListener listener)

      Adds a LocalizationManager listeners
      Parameters:
        `listener` - A `TextManagerListener` listener to be added into a collection of listeners

    - #### removeListener

          public void removeListener(TextManagerListener listener)

      Removes a LocalizationManager listeners
      Parameters:
        `listener` - A `TextManagerListener` listener to be removed from a collection of listeners

    - #### registerBundle

          public void registerBundle(java.lang.String bundleFamilyName)

      Registers a specific bundle (identified by its filename)
      Specified by:
        `registerBundle` in interface `TextManager`
      Parameters:
        `bundleFamilyName` - Filename of a bundle-family

    - #### unregisterBundle

          public void unregisterBundle(java.lang.String bundleFamilyName)

      Removes a specific bundle (identified by its filename)
      Specified by:
        `unregisterBundle` in interface `TextManager`
      Parameters:
        `bundleFamilyName` - Filename of a bundle-family

    - #### registerClassBundle

          public void registerClassBundle(java.lang.Class<?> clazz)

      Registers a specific bundle (identified by its class)
      Specified by:
        `registerClassBundle` in interface `TextManager`
      Parameters:
        `clazz` - Class of a bundle-family

    - #### unregisterClassBundle

          public void unregisterClassBundle(java.lang.Class<?> clazz)

      Removes a specific bundle (identified by its class)
      Specified by:
        `unregisterClassBundle` in interface `TextManager`
      Parameters:
        `clazz` - Class of a bundle-family