I'd recommend MSDN for things such as this, but here's a summary for you.
-
new ThreadStart (Method1)
-
A Thread needs somewhere to start, which obviously will be a Method. Normally this will be
a parameterless method with no return. e.g.
Overall we call this starting point a ThreadStart, and we pass in a method to the constructor.
- new Thread (new ThreadStart (Method1))
This simply takes what we had before 1 step further. We are now constructing a new Thread, and passing
a ThreadStart to the constructor (which in this case is being constructed on the same line of code). This
tells the Thread whereabouts it should start.
- Thread firstThread = new Thread (new ThreadStart (Method1));
You're now taking it further by saving a reference to your Thread in a parameter called firstThread so you
can then refer to it later.