Map<String, String> map1 = new HashMap<String, String>();
map1.put("count", "256");
map1.put("port", "85.6");
//将map集合存入redis中
redisService.setMoreHash("宝山区", map1);
Map<String, String> hash = redisService.getHash("宝山区");
//通过map集合中的键取值
String str = hash.get("port");
System.out.println(str);
redis存入和取出Map集合问题
最新推荐文章于 2023-03-10 16:38:58 发布