예제 #1
0
        public ObservableCollection <Dog> AllDogs()
        {
            ObservableCollection <Dog> Dogs = new ObservableCollection <Dog>();

            foreach (var dogDataBase in DogDataProvider.AllDogs())
            {
                Dog dog = new Dog
                {
                    Title = dogDataBase.DogId.ToString(),
                    Breed = dogDataBase.Breed,
                    Image = dogDataBase.Image_data
                };

                Dogs.Add(dog);
            }

            return(Dogs);
        }
예제 #2
0
        public ObservableCollection <Dog> ListOfAvailable(int start, int cnt)
        {
            Thread.Sleep(delay);

            ObservableCollection <Dog> Dogs = new ObservableCollection <Dog>();

            foreach (var dogDataBase in DogDataProvider.DataSegment(start, cnt))
            {
                Dog dog = new Dog
                {
                    Title = dogDataBase.DogId.ToString(),
                    Breed = dogDataBase.Breed,
                    Image = dogDataBase.Image_data
                };

                Dogs.Add(dog);
            }

            return(Dogs);
        }
예제 #3
0
 public int Available()
 {
     Thread.Sleep(delay);
     return(DogDataProvider.NumberOfDogs());
 }