Package fr.becpg.repo.helper
Class TranslateHelper
java.lang.Object
fr.becpg.repo.helper.TranslateHelper
TranslateHelper class.
- Version:
- $Id: $Id
- Author:
- matthieu
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetConstraint(String constraintName, String value, boolean useDefaultLocale) getConstraint.static StringgetConstraint(String constraintName, String value, Locale locale) getConstraint.static StringgetLocaleAwarePath(String path) getLocaleAwarePath.static org.alfresco.service.cmr.repository.MLTextgetTemplateDescriptionMLText(org.alfresco.service.namespace.QName classQName) getTemplateDescriptionMLText.static org.alfresco.service.cmr.repository.MLTextgetTemplateModelMLText(org.alfresco.service.namespace.QName classQName, String key) getTemplateModelMLText.static org.alfresco.service.cmr.repository.MLTextgetTemplateTitleMLText(org.alfresco.service.namespace.QName classQName) getTemplateTitleMLText.static StringgetTranslatedBoolean(Boolean b, boolean useDefaultLocale) getTranslatedBoolean.static org.alfresco.service.cmr.repository.MLTextgetTranslatedKey(String key) getTranslatedKey.static StringgetTranslatedPath(String name) Translate the name of the path.static org.alfresco.service.cmr.repository.MLTextgetTranslatedPathMLText.
-
Field Details
-
PATH_MSG_PFX
- See Also:
-
LIST_CONSTRAINT_MSG_PFX
- See Also:
-
MESSAGE_TRUE
- See Also:
-
MESSAGE_FALSE
- See Also:
-
logger
private static final org.apache.commons.logging.Log logger
-
-
Constructor Details
-
TranslateHelper
private TranslateHelper()
-
-
Method Details
-
getTranslatedPath
Translate the name of the path.- Parameters:
name- the name- Returns:
- the translated path
-
getTranslatedPathMLText
getTranslatedPathMLText.
- Parameters:
name- aStringobject.- Returns:
- a
MLTextobject.
-
getTranslatedBoolean
getTranslatedBoolean.
-
getConstraint
getConstraint.
-
getTranslatedKey
getTranslatedKey.
- Parameters:
key- the key to search for translations- Returns:
- the MLText with the translations for all the languages supported.
List defined in
RepoConsts
-
getTemplateModelMLText
public static org.alfresco.service.cmr.repository.MLText getTemplateModelMLText(org.alfresco.service.namespace.QName classQName, String key) getTemplateModelMLText.
- Parameters:
classQName- aQNameobject.key- aStringobject.- Returns:
- a
MLTextobject.
-
getTemplateTitleMLText
public static org.alfresco.service.cmr.repository.MLText getTemplateTitleMLText(org.alfresco.service.namespace.QName classQName) getTemplateTitleMLText.
- Parameters:
classQName- aQNameobject.- Returns:
- a
MLTextobject.
-
getTemplateDescriptionMLText
public static org.alfresco.service.cmr.repository.MLText getTemplateDescriptionMLText(org.alfresco.service.namespace.QName classQName) getTemplateDescriptionMLText.
- Parameters:
classQName- aQNameobject.- Returns:
- a
MLTextobject.
-
getConstraint
getConstraint.
-
getLocaleAwarePath
getLocaleAwarePath.
-