public List <IOpstiDomenskiObjekat> VratiListu(OleDbDataReader citac) { List <IOpstiDomenskiObjekat> lista = new List <IOpstiDomenskiObjekat>(); while (citac.Read()) { Tim t = new Tim() { TimID = Convert.ToInt32(citac["timID"]), NazivTima = Convert.ToString(citac["nazivTima"]) }; lista.Add(t); } return(lista); }
public IOpstiDomenskiObjekat VratiObjekat(OleDbDataReader citac) { IOpstiDomenskiObjekat objekat = null; while (citac.Read()) { objekat = new Tim { TimID = Convert.ToInt32(citac["timID"]), NazivTima = Convert.ToString(citac["nazivTima"]), ClanoviTima = new List <ClanTima>() }; break; } return(objekat); }