Class DefaultLocalizedFieldMapper

java.lang.Object
ch.tocco.nice2.model.entity.impl.entity.DefaultLocalizedFieldMapper
All Implemented Interfaces:
LocalizedFieldMapper, LocalizedFieldNamingStrategy

public class DefaultLocalizedFieldMapper extends Object implements LocalizedFieldMapper
Current impl used for making localized field names.

It appends the language to the field except for the default language. Thus if the availabe languages are "de", "en", "fr" and the default is "de" then a field with the base name "foo" will be created as "foo", "foo_en" and "foo_fr".

The field name mapping strategy may be "overriden" from another module by contributing an own implementation of LocalizedFieldNamingStrategy. Only one such contribution is allowed. If none is contributed, the default one is used.

DefaultLocalizedFieldMapper