private Thread MTPrivate1(List<Book> result, Object sync)
{
Thread t1 = ThreadFactory.CreateNew(new ThreadStart(() =>
{
IProfiler profiler = Profiler.Instance;
using (profiler.Step("MT1"))
{
lock (sync)
{
result.Add(new Book { Auther = "T1Author", Name = "T1Name", Pages = 2 });
LinqTestMethod();
//Thread.Sleep(5000);
}
}
}));
System.Diagnostics.Debug.WriteLine("MT1 - " + t1.ManagedThreadId.ToString());
t1.Name = "Mt1";
return t1;
}