2 Replies Latest reply: Mar 23, 2007 4:38 PM by 807606 RSS

    creating LinkdedHashMap or TreeMap from Map

    807606
      I have a Map that I want to sort. It looks like i can use LinkedHashMap or TreeMap. Either way, I don't get the syntax to create these from a Map:

      LinkedHashMap(Map<? extends K,? extends V> m)

      So m is the Map, so let's say "myMap":

      LinkedHashMap(Map<? extends K,? extends V> myMap)

      but what is the "?"
      and K means Key, V means values, but I don't get it.
      Can someone give me a line of code for this?
      Thanks,