String description = "你所要比较的字符串";

HashMap hashmap = new HashMap();
hashmap.put("prepare receive button custom key", "");
hashmap.put("cash_pay_all button custom key for check out", "");
hashmap.put("confirm receive button custom key", "");
hashmap.put("prepare receive button custom key", "");
hashmap.put("cash_pay_all button custom key for check out", "");
hashmap.put("confirm receive button custom key", "");if (hashmap.containsKey(description)) {
//如果包含,进行相关操作
}
本文介绍了一种使用Java中的HashMap来存储和管理不同按钮的自定义键的方法,并演示了如何检查一个特定的字符串是否作为键存在于HashMap中。
1520

被折叠的 条评论
为什么被折叠?



