code: @Override
      @SuppressWarnings("unchecked")
      /**
       * override to support ordering of returned keys.
       */
      public Iterator<String> getKeys() {
  
          final Iterator tempKeysIter = super.getKeys();
          final List<String> keys = sortKeys(tempKeysIter);
  
          return keys.iterator();
      }
docs: each call to this method method will first sort the keys and then return
  the iterator.