Class MultiTranslationQuery

java.lang.Object
com.e1c.langtool.query.TranslationQuery
com.e1c.langtool.query.MultiTranslationQuery
All Implemented Interfaces:
IMultiTranslationQuery

public final class MultiTranslationQuery extends TranslationQuery implements IMultiTranslationQuery
Encapsulates a translation query for multi texts.
  • Method Details

    • createQuery

      public static IMultiTranslationQuery createQuery(List<String> texts, String source, String target, boolean isProcessing)
      Creates a new translation query for multi texts.
      Parameters:
      text - the list of texts to translate
      sourceLocale - the source language of texts
      targetLocale - the target language to translate
      isProcessing - information text processing is needed or not
      Returns:
      a new translation query for multi texts
    • createQuery

      public static IMultiTranslationQuery createQuery(List<String> texts, String source, String target)
      Creates a new translation query with processing for multi texts.
      Parameters:
      text - the list of texts to translate
      sourceLocale - the source language of texts
      targetLocale - the target language to translate
      isProcessing - information text processing is needed or not
      Returns:
      a new translation query for multi texts
    • getTexts

      public List<String> getTexts()
      Description copied from interface: IMultiTranslationQuery
      Returns the texts to translate.
      Specified by:
      getTexts in interface IMultiTranslationQuery
      Returns:
      the list of texts to translate
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class TranslationQuery
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class TranslationQuery
    • getSourceLanguage

      String getSourceLanguage()
      Returns the code of source language of text.
      Returns:
      the code of source language. Can't be null.
    • getTargetLanguage

      String getTargetLanguage()
      Returns the code of target language to translate.
      Returns:
      the code of target language to translate. Can't be null.
    • isProcessingNeeded

      boolean isProcessingNeeded()
      Returns true if the text (or texts) needs of processing.
      Returns:
      true if the text (or texts) needs of processing