Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Gh pages 1.0 #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
maskleo merged 14 commits into gh-pages from gh-pages-1.0
Apr 19, 2018
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
添加上下文链接
  • Loading branch information
maskleo committed Apr 19, 2018
commit c7900e4db5cb4a23c2d74744e87c206323fcf91e
49 changes: 5 additions & 44 deletions ch10/00_Collections.md
View file Open in desktop
Original file line number Diff line number Diff line change
@@ -1,50 +1,11 @@
《《《 [返回首页](../README.md) <br/>
《《《 [上一节](../ch09/05_Subject-Observer.md)

# 集合

`Java` 集合框架是 `java.util` 和 `java.util.concurrent` 包中的一组接口和类。他们为客户程序提供了如何组织其对象的各种模型以及每种模型的各种实现。这些模型有时被称为抽象数据类型,我们需要它们,因为不同的程序需要不同的方式来组织它们的对象。在一种情况下,您可能希望将程序的对象组织在顺序列表中,因为它们的排序很重要,并且有重复。另一种情况是,一个集合可能是正确的数据类型,因为现在的排序并不重要,你想放弃重复。这两种数据类型(以及其他)由集合框架中的不同接口表示,我们将在本章中查看它们的使用示例。但那不是全部;这些数据类型中没有一个具有单一的"最佳"实现 - 也就是说,对于所有操作,其中一个实现比所有其他实现更好。例如,链接列表可能比用于从中间插入和删除元素的列表的阵列实现更好,但是对于随机访问更糟糕。因此,为您的程序选择正确的实施方式涉及知道如何使用以及可用的方式。

本书的这一部分首先概述框架,然后详细介绍每个主界面及其标准实现。最后,我们将看看 `Collections` 类中提供的专用实现和通用算法。













































《《《 [下一节](01_The_Main_Interfaces_of_the_Java.md) <br/>
《《《 [返回首页](../README.md)
8 changes: 7 additions & 1 deletion ch10/01_The_Main_Interfaces_of_the_Java.md
View file Open in desktop
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
《《《 [返回首页](../README.md) <br/>
《《《 [上一节](00_Collections.md)

## Java集合框架的主要接口

图 `10-1` 显示了 `Java` 集合框架的主要接口,以及另外一个 `Iterable`--它不在框架中,但是它是一个重要的附件。其目的如下:
Expand All @@ -14,4 +17,7 @@

图 `10-1`。 `Java`集合框架的主要接口

第 `12` 章到第 `16` 章将依次关注每个集合框架接口。首先,虽然在第 `11` 章中,我们需要介绍贯穿整个框架设计的一些初步想法。
第 `12` 章到第 `16` 章将依次关注每个集合框架接口。首先,虽然在第 `11` 章中,我们需要介绍贯穿整个框架设计的一些初步想法。

《《《 [下一节](../ch11/00_Preliminaries.md) <br/>
《《《 [返回首页](../README.md)

AltStyle によって変換されたページ (->オリジナル) /