I need to have a thread signal another if the user wishes to interrupt execution, however I'm unsure about how to implement the signaling/signal-checking mechanism. I wouldn't like to have a singleton in my project (like a global bool
), but is there an alternative?
In this thread people suggest proper structures for that in C++, but I don't know about anything similar in .NET. Could somebody please shed some light?