Java-preliminary Understanding-Common Object API (collection framework-map collection common subclass objects)

Source: Internet
Author: User
Tags set set

One.

I'm done with the map collection, by the way, little things.

A common subclass of the map collection:

Hashtable research is data structure, hash in 1.0 out, there is no table. At that time, single-column collections were only vectors, and double-row collections were hashtable. The internal structure is a hash table. is synchronous. HashMap and Hashtable are different, the efficiency is no longer said. is a HashMap API note that is not synchronized.

Hashtable, it does not support null keys and null values. The difference between them during the interview.

The system above is similar to a set system, which is set set, HashSet and TreeSet, see. You can save a couple at a time. Just let the value be a uniform object and it's done. I just manipulate the key, which is the set set. The underlying code of the set set is the map collection to implement, in fact, the map has been able to solve the problem. Why do we have set? It is to ensure that the set that is generated by the uniqueness of the element in a single-column collection is for more convenient application, otherwise the map will be done.

Hashtable will not demonstrate, in fact, we will use. Because it has sub-class, the use of high frequency, is the properties.

Properties are typically used for property sets, which are used to store information about a configuration file. A configuration file is typically a key and a value. Not currently, as it is combined with I/O technology to work. This is an object, a container, that is in the map collection.

Java-preliminary Understanding-Common Object API (collection framework-map collection common subclass objects)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.