linkedHashMap
时间: 2023-08-22 21:14:35 浏览: 101
LinkedHashMap是一个继承自HashMap的类,它实现了Map接口。它的继承关系可以表示为:public class LinkedHashMap<K,V> extends HashMap<K,V> implements Map<K,V>。\[1\]与HashMap不同的是,LinkedHashMap还维护了一个Entry的双向链表,这个链表保证了插入的Entry中的顺序,也就是说,插入的顺序会被保留下来。这也是Linked的含义。\[2\]LinkedHashMap的结构图如下:\[2\]。
LinkedHashMap的概述可以表示为:public class LinkedHashMap<K,V> extends HashMap<K,V> implements Map<K,V>。\[3\]
#### 引用[.reference_title]
- *1* [Java基础汇总(十六)——LinkedHashMap](https://blog.csdn.net/weixin_45864705/article/details/127145695)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insert_down28v1,239^v3^insert_chatgpt"}} ] [.reference_item]
- *2* *3* [超详细LinkedHashMap解析](https://blog.csdn.net/qq_40050586/article/details/105851970)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v91^insert_down28v1,239^v3^insert_chatgpt"}} ] [.reference_item]
[ .reference_list ]
阅读全文