I am building a multi-platform library for graphs and I’d really need a
TreeMap to sort the frontier. I was trying to rewrite it as is in
java.utils but its implementation is so rooted in the JDK that is insane (if not illegal) to translate all the files required from Java to Kotlin just for the class I need.
I never realized how hard is to manipulate complex data without
Anyone knows an intelligent way to get a TreeMap up and running other then studying it and manually implementing it from scratch?
An alternative would be to use a wrapped
.put() creates a new map with the new entry in the correct position.