KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Talking about System.Collections.Generic.List<T> here. With example below can Method1 and Method2 execute and the same time, on different threads without any problems? Thanks class Test { private readonly List<MyData> _data; public Test() { _data = LoadData(); } private List<MyData> LoadData() { //Get data from dv. } public void Method1() { foreach (var list in _data) { //do something } } public void Method2() { foreach (var list in _data) { //do something } } }
Tags (comma-separated)
Save Edits
Cancel