java.lang.Object
org.sentrysoftware.metricshub.engine.connector.model.common.TranslationTable
All Implemented Interfaces:
Serializable, ITranslationTable

public class TranslationTable extends Object implements ITranslationTable
Represents a translation table used for mapping values in the context of a connector.
See Also:
  • Constructor Details

    • TranslationTable

      public TranslationTable()
  • Method Details

    • copy

      public TranslationTable copy()
      Creates a deep copy of the TranslationTable instance.
      Specified by:
      copy in interface ITranslationTable
      Returns:
      A new instance of TranslationTable with copied translations.
    • update

      public void update(UnaryOperator<String> updater)
      Updates the translation values using the specified updater.
      Specified by:
      update in interface ITranslationTable
      Parameters:
      updater - An operation on a single operand that produces a result of the same type as its operand.
    • setTranslation

      public void setTranslation(String key, String value)
      Sets a translation for the specified key.
      Parameters:
      key - The key for the translation.
      value - The translation value.
    • getTranslations

      public Map<String,String> getTranslations()
      Retrieves the translations mapping.
      Returns:
      The translations mapping.