예제 #1
0
        public List <Genre> GetAllGenres()
        {
            List <Genre>            genres        = new List <Genre>();
            CoreToDataMapperService mapperService = new CoreToDataMapperService();

            foreach (IGenre genreData in _genreRepository.GetAllGenres())
            {
                genres.Add(mapperService.MapGenreDataToCore(genreData));
            }
            return(genres);
        }
예제 #2
0
        public Genre GetGenre(int id)
        {
            CoreToDataMapperService mapperService = new CoreToDataMapperService();

            return(mapperService.MapGenreDataToCore(_genreRepository.GetGenre(id)));
        }