Fix _NOUTF flag handling in "--i18n"
[jvcard.git] / src / be / nikiroo / jvcard / resources / bundles / TransBundle.java
index c79b0b69b62734d7b308ed07a50247fa15b7188e..6ff63bffeb9e3eebd17e6346d06a037d28258f98 100644 (file)
@@ -148,6 +148,17 @@ public class TransBundle extends Bundle<StringId> {
                StringId.writeHeader(writer, name);
        }
 
+       @Override
+       protected void writeValue(Writer writer, StringId id) throws IOException {
+               super.writeValue(writer, id);
+
+               String name = id.name() + "_NOUTF";
+               if (map.containsKey(name)) {
+                       String value = map.getString(name).trim();
+                       writeValue(writer, name, value);
+               }
+       }
+
        /**
         * Return the {@link Locale} representing the given language.
         * 
@@ -180,5 +191,4 @@ public class TransBundle extends Bundle<StringId> {
 
                return locale;
        }
-
 }