Multi-threaded join () [C #, Java]

Source: Internet
Author: User

There are two methods to implement multithreading in Java: one is to continue the Thread class and the other is to implement the runable interface.

Detail: http://www.cnblogs.com/qinpengming/admin/EditPosts.aspx? Opt = 1

What is join () in multiple threads? C # version

Http://zjj1211.blog.51cto.com/1812544/368175 --- Yi

Http://blog.sina.com.cn/s/blog_6680da090100s9lr.html

Java version of join ()

Http://zjj1211.blog.51cto.com/1812544/368175 thread and runable

The synchronous version of The http://hi.baidu.com/lizhenzhen1020/blog/item/cd349658963cce5afbf2c025.html runnable and the intermediate part of

The use of http://www.2cto.com/kf/201109/102666.html thread for join in Java Multithreading

Differences between http://luckyapple.iteye.com/blog/457298 Java multithreading suspend (), resume () and wait (), notify ()

Conclusion: The function of the join method is to convert the asynchronous thread into synchronous execution. That is to say, after the start method of the thread instance is called, this method will return immediately. If a value calculated by this thread needs to be used after the start method is called, you must use the join method. If the join method is not used, it cannot be guaranteed that the thread will be executed completely when a statement following the start method is executed. After the join method is used, the program will not execute until the thread exits.

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.