Exemplo n.º 1
0
        public static void DeleteMusic()
        {
            var videoFound = FindMusicById();

            if (videoFound != null)
            {
                allMusics.Remove(videoFound);
            }
            Introduction.ExitorNot();
        }
Exemplo n.º 2
0
        public static void EditVideo()
        {
            var Music = FindMusicById();

            WriteLine("Enter the new name of the music:\n");
            Music.Name = ReadLine();
            WriteLine("Enter the new style of the music:\n");
            Music.Style = ReadLine();
            WriteLine("You successfully changed the nem of the music");
            Introduction.ExitorNot();
        }
Exemplo n.º 3
0
        public static void ShowAllMusics()
        {
            WriteLine("Here you can see all the stored musics:\n");

            foreach (var item in allMusics)
            {
                WriteLine($"Id: { item.Id}\n" +
                          $"Name: {item.Name }\n" +
                          $"Style: {item.Style }\n");
            }
            WriteLine("\n");
            Introduction.ExitorNot();
        }
Exemplo n.º 4
0
        public static void AddMusic()
        {
            int id = allMusics.Count + 1;

            WriteLine("The name of the music: \n");
            var name = ReadLine();

            WriteLine("The Style of the music: \n");
            var style = ReadLine();

            allMusics.Add(new Music()
            {
                Id    = id++,
                Name  = name,
                Style = style
            });
            WriteLine("You successfully added " + name + " to the list");
            Introduction.ExitorNot();
        }