I have this nested list :
public List<List<string>> pcList = new List<List<string>>();
How can I create getters and setters for it? I have tried everything out there on the internet and nothing seems to work
Thx!
EDIT: So, In class Pc I have this code:
class PC
{
public List<List<string>> pcList = new List<List<string>>();
public List<string> subList = new List<string>();
}
so the pcList is the "parent" list and the sublist is actually the place where I add each pc with its info. I have a method where I populate the lists. Then I want to use an object of this class in another class called X, let's say. I have tried to simply access the lists by using object.ListName but it doesn't work.