public void Delete() { if (VendorList.Contains(VendorId)) { VendorList.GetVendorList().Remove(this); } }
public void Save() { if (!VendorList.Contains(VendorId)) { VendorList.GetVendorList().Add(this); IsNew = false; } }
private static void BuildInstance() { _instance = new VendorList(); new Vendor { FirstName = "Ella", LastName = "Fitzgerald", Town = "Newport News", State = States.VA }.Save(); new Vendor { FirstName = "Louis", LastName = "Armstrong", Town = "New Orleans", State = States.LA }.Save(); }