Interface LocalisationFactory
-
public interface LocalisationFactory
Factory related to the localisation of process model objects.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <T extends PluginDataContainer>
TcreateLocalisedView(Class<T> clazz, T target, Locale locale)
Create a localised view on the giventarget
object.
-
-
-
Method Detail
-
createLocalisedView
<T extends PluginDataContainer> T createLocalisedView(Class<T> clazz, T target, Locale locale)
Create a localised view on the giventarget
object. For performance reasons, thetarget
object will be returned, if no translation is found in the plug-in data or the designated locale isnull
.
When requiring equality of the created view, for instance when storing in a hashing collection, make sure that theObject.equals(Object)
implementations of the implementing classes are prepared for comparing proxy instances. Usually they need toWrappingProxy.unwrap(Class)
the expected class.- Type Parameters:
T
- The type of thetarget
.- Parameters:
clazz
- The model interface, i.e. the interface for accessing thetarget
target
- The actual model object.locale
- The locale for which the values should be translated.- Returns:
- A translating view on the target object, or the target object itself, if no translation is available.
-
-