具体类实现的效果也存在差异,比如 TreeSet 这个实现类:
A NavigableSet implementation based on a TreeMap. The elements are ordered using their natural ordering, or by a Comparator provided at set creation time, depending on which constructor is used.
就明确表示“The elements are ordered ”,采用:“natural ordering” 或 Comparator。