Class ADTranslationAbleHelper
- java.lang.Object
-
- de.mid.innovator.srv2api.icw2meta.ADTranslationAbleHelper
-
public abstract class ADTranslationAbleHelper extends java.lang.ObjectThis is a utility class for ADTranslationAble that provides static methods for creation or other purposes.- See Also:
ADTranslationAble
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcleanUpUnappropriatedTranslations(SrvContext srvCtx)For eachELTranslatedValuewithout connection the translated element is calculated and if found the missing connection is created.static ARG_AskgetModifyTranslationLocaleCheck(SrvContext srvCtx, java.util.List<K_LOCALE> seq)Checks whether the modification of translation languages deletes translations.static java.util.List<K_LOCALE>getModifyTranslationLocaleInit(SrvContext srvCtx)Returns the list ofMM2Localevalues which are allowed as translation language.static ARG_GetPropertyTranslationsgetPropertyTranslations(SrvContext srvCtx, java.util.List<? extends ADClientAble> seqElem, java.util.List<? extends MM2Locale> seqLang)Calculates all properties for the selected elements and all existing translations.static ARG_AskgetSetNotToTranslateAttributeCheck(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr)Checks whether existing translations are deleted, if the specified attributes are marked as not necessary for translation.static ARG_TranslationMatrixgetTranslations(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends ADTranslationAble> seqLang, boolean isExport)Returns a list of translatable elements with properties and translations for each specified language.static voidmodifyTranslationLocale(SrvContext srvCtx, java.util.List<K_LOCALE> seq)Modify the list of translation languages.static voidresetNotToTranslateAttribute(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr)static voidsetNotToTranslateAttribute(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr)
-
-
-
Method Detail
-
getPropertyTranslations
public static ARG_GetPropertyTranslations getPropertyTranslations(SrvContext srvCtx, java.util.List<? extends ADClientAble> seqElem, java.util.List<? extends MM2Locale> seqLang) throws InoNetException, SrvErrorException
Calculates all properties for the selected elements and all existing translations.- Parameters:
srvCtx- The context of the related innovator server.seqElem- list of selected elementsseqLang- list of selected languages- Throws:
InoNetExceptionSrvErrorException
-
getTranslations
public static ARG_TranslationMatrix getTranslations(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends ADTranslationAble> seqLang, boolean isExport) throws InoNetException, SrvErrorException
Returns a list of translatable elements with properties and translations for each specified language.- Parameters:
srvCtx- The context of the related innovator server.seqElem- list of elements to be translatedseqLang- list of translation languagesisExport- true, if the elements are exported for translation- Throws:
InoNetExceptionSrvErrorException
-
getModifyTranslationLocaleCheck
public static ARG_Ask getModifyTranslationLocaleCheck(SrvContext srvCtx, java.util.List<K_LOCALE> seq) throws InoNetException, SrvErrorException
Checks whether the modification of translation languages deletes translations.- Parameters:
srvCtx- The context of the related innovator server.seq-- Throws:
InoNetExceptionSrvErrorException
-
getModifyTranslationLocaleInit
public static java.util.List<K_LOCALE> getModifyTranslationLocaleInit(SrvContext srvCtx) throws InoNetException, SrvErrorException
Returns the list ofMM2Localevalues which are allowed as translation language.- Parameters:
srvCtx- The context of the related innovator server.- Throws:
InoNetExceptionSrvErrorException
-
getSetNotToTranslateAttributeCheck
public static ARG_Ask getSetNotToTranslateAttributeCheck(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr) throws InoNetException, SrvErrorException
Checks whether existing translations are deleted, if the specified attributes are marked as not necessary for translation.- Parameters:
srvCtx- The context of the related innovator server.seqElem- list of elements with translatable attributesseqAttr- list of translatable attributes- Throws:
InoNetExceptionSrvErrorException
-
cleanUpUnappropriatedTranslations
public static void cleanUpUnappropriatedTranslations(SrvContext srvCtx) throws InoNetException, SrvErrorException
For eachELTranslatedValuewithout connection the translated element is calculated and if found the missing connection is created. Otherwise theELTranslatedValueis deleted.- Parameters:
srvCtx- The context of the related innovator server.- Throws:
InoNetExceptionSrvErrorException
-
modifyTranslationLocale
public static void modifyTranslationLocale(SrvContext srvCtx, java.util.List<K_LOCALE> seq) throws InoNetException, SrvErrorException
Modify the list of translation languages.- Parameters:
srvCtx- The context of the related innovator server.seq-- Throws:
InoNetExceptionSrvErrorException
-
resetNotToTranslateAttribute
public static void resetNotToTranslateAttribute(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr) throws InoNetException, SrvErrorException
For each specified pair of element and attribute the attribute is marked as necessary for translation.- Parameters:
srvCtx- The context of the related innovator server.seqElem- list of elements with translatable attributesseqAttr- list of translatable attributes- Throws:
InoNetExceptionSrvErrorException
-
setNotToTranslateAttribute
public static void setNotToTranslateAttribute(SrvContext srvCtx, java.util.List<? extends ELUUIDAble> seqElem, java.util.List<? extends MM2Attribute> seqAttr) throws InoNetException, SrvErrorException
For each specified pair of element and attribute the attribute is marked as not necessary for translation.- Parameters:
srvCtx- The context of the related innovator server.seqElem- list of elements with translatable attributesseqAttr- list of translatable attributes- Throws:
InoNetExceptionSrvErrorException
-
-