On 06/11/14 09:42, Gerd Petermann wrote:
@Steve:
I am not sure what to do here. A method like City.getName() should
probably used the getEncText() method if getText() returns null?
But getEncText() returns a char[] while getText() returns a String,
so that seems to be inefficient :-(
No, not without further thought anyway. It is done this way so that it
fails if used in the wrong way.
The problem is that we have the real name in unicode and a file
representation that can be very different (due to character set and
transliteration) and it is important to sort on the correct one.
In this particular case of adding to a hash map where the ordering does
not matter to it, then it would probably be OK to compare using the
string name, but that is quite an unusual (and unexpected to me!) case.
..Steve
_______________________________________________
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev