简体   繁体   中英

Internal Thread vs External Thread in c#

I read an Artcle about thread safty's technique in c#, it said that

Lock or Monitor is one and same it works with internal threads generated by an application. Lock or monitor does not have control over external threads.

i didn't understand what are Internal thread and External therad ? what does it means?

From your quote "internal threads generated by an application" From later on in the article "External threads basically coming from outside of an application"

Internal threads, in this context, are created by the application itself - so Lock & Monitor could be used allow synchronisation of access to a resource by different threads within a single application.

External threads are created by other applications - so Mutex & Semaphore could be used to allow synchronisation of access to a resource by different applications.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM