Example #1
0
        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);
        }
Example #2
0
        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);
        }