public void GetUserInput() { StreamCityContent newContent = new StreamCityContent(); Console.WriteLine("Enter the name of your content:"); string name = Console.ReadLine(); newContent.Name = name; Console.WriteLine("How long is the content in hours?"); double duration = double.Parse(Console.ReadLine()); newContent.Duration = duration; Console.WriteLine("Is your content a movie? y/n"); string isMovieStr = Console.ReadLine().ToLower(); bool isMovie; if (isMovieStr.Contains("y")) { isMovie = true; } else { isMovie = false; } newContent.IsMovie = isMovie; Console.WriteLine("What genre is your content?\n\t" + "1. Action\n\t" + "2. Comedy\n\t" + "3. Thriller"); int genreInt = int.Parse(Console.ReadLine()); GenreType genre = _streamCityRepo.GetGenreFromInt(genreInt); newContent.TypeOfGenre = genre; _streamCityRepo.AddContentToList(newContent); }
public void AddContentToQueue(StreamCityContent content) { _contentQueue.Enqueue(content); }
public void RemoveContentFromList(StreamCityContent content) { _contentList.Remove(content); }
public void AddContentToList(StreamCityContent content) { _contentList.Add(content); }