关于协议排序



is java code

sort a->z



  StringBuilder result = new StringBuilder();
  Object[] keys = paramsMap.keySet().toArray();
  Arrays.sort(keys);

  for (Object key : keys) {
      result.append(key);
      result.append(paramsMap.get(key));
  }

  //参数排序后的字符串
  String paramsSortString = result.toString();
  

你可能感兴趣的:(关于协议排序)