private static void DataLoad(string filepath) { staff = new MyList <Angajat>(); StreamReader dataLoad = new StreamReader(filepath); string line = dataLoad.ReadLine(); while (line != null) { string[] datas = line.Split(' '); string lastName = datas[0]; string firstName = datas[1]; string[] fullDate = datas[2].Split('/'); DateTime date = new DateTime(int.Parse(fullDate[0]), int.Parse(fullDate[1]), int.Parse(fullDate[2])); Angajat employee = new Angajat(lastName, firstName, date); staff.Add(employee); line = dataLoad.ReadLine(); } }
public void Remove(Angajat employee) { this.list.Remove(employee); }
public void Add(Angajat employee) { this.list.Add(employee); }
public MyList(Angajat employee) { this.list.Add(employee); }