Container thread security

Source: Internet
Author: User

Java container thread security

1. hashset non-thread security [1]

 

2. treeset non-thread security [2]

3. linkedhashset non-thread security [3]

4. arraylist non-thread security [4]

5. Producer list non-thread security [5]

6. hashmap non-thread security [6]

7. treemap non-thread security [7]

8. linkedhashmap non-thread security [8]

 

9. hashtable thread security [9]

10. Vector thread security [10]

 


 

 

 

[1] http://download.oracle.com/javase/1.5.0/docs/api/java/util/HashSet.html

 

[2] http://download.oracle.com/javase/1.5.0/docs/api/java/util/TreeSet.html

 

[3] http://download.oracle.com/javase/1.5.0/docs/api/java/util/LinkedHashSet.html

[4] http://download.oracle.com/javase/1.5.0/docs/api/java/util/ArrayList.html

【5】 http://download.oracle.com/javase/1.5.0/docs/api/java/util/LinkedList.html

[6] http://download.oracle.com/javase/1.5.0/docs/api/java/util/HashMap.html

【7】 http://download.oracle.com/javase/1.5.0/docs/api/java/util/TreeMap.html

[8] http://download.oracle.com/javase/1.5.0/docs/api/java/util/LinkedHashMap.html

【9】 http://download.oracle.com/javase/1.5.0/docs/api/java/util/Hashtable.html

Http://download.oracle.com/javase/1.5.0/docs/api/java/util/Vector.html (10)

 

 

C ++ container thread security

Security is not considered in the standard, and is actually not safe.

 

OBJ-C thread security

There is only one obj-C container, nsmutablearray and nsarray.

The latter is read-only after being built, and it is of course thread security.

The former is variable, and obj-C is not thread-safe, so you can only manually synchronize

In general, mutable is not safe.

[11] http://developer.apple.com/mac/library/documentation/cocoa/conceptual/

Multithreading/threadsafetysummary/threadsafetysummary.html

 

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.