/*行转列*/
private List<Map> rowToColumn(List<Map<String, Object>> maps) {
if (maps.size() <= 0) {
return null;
}
Map<String, Object> object = maps.get(0);
Set<String> keys = object.keySet();
Map<String, List<String>> result = new HashMap<>();
for (String key : keys) {
List<String> data = new ArrayList<>();
result.put(key, data);
}
int size = maps.size();
for (int i = 0; i < size; i++) {
Map<String, Object> map = maps.get(i);
for (String key : keys) {
List<String> data = result.get(key);
data.add(map.get(key).toString());
}
}
List<Map> list = new ArrayList<>();
list.add(result);
return list;
}