OsmAnd/OsmAnd-java/src/main/java/net/osmand/binary/StringBundleWriter.java
2020-03-14 21:18:30 +03:00

26 lines
523 B
Java

package net.osmand.binary;
import net.osmand.binary.StringBundle.Item;
import java.util.Map.Entry;
public abstract class StringBundleWriter {
private StringBundle bundle;
public StringBundleWriter(StringBundle bundle) {
this.bundle = bundle;
}
public StringBundle getBundle() {
return bundle;
}
protected abstract void writeItem(String name, Item item);
public void writeBundle() {
for (Entry<String, Item> entry : bundle.getMap().entrySet()) {
writeItem(entry.getKey(), entry.getValue());
}
}
}