Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有谁知道在不提前知道所有键的情况下枚举捆绑包的所有键值对的方法?
我认为获得所有键值对的唯一方法是使用键枚举keySet(),然后枚举get()其相对值。例如:
keySet()
get()
for(String key : bundle.keySet()){ Object obj = bundle.get(key); //later parse it as per your required type }