Ejemplo n.º 1
0
 public void ClearLibrary()
 {
     if (counter == 0)
     {
         ExccessBookkeepingEmpty err = new ExccessBookkeepingEmpty("ERROR!!!\n Bookkeeping is empty");
         throw err;
     }
     else
     {
         counter = 0;
         data.Clear();
         Console.WriteLine("Бухгалтерия очищена!");
     }
 }
Ejemplo n.º 2
0
 public void Output()
 {
     if (counter == 0)
     {
         ExccessBookkeepingEmpty err = new ExccessBookkeepingEmpty("ERROR!!!\n Bookkeeping is empty");
         throw err;
     }
     else
     {
         foreach (object i in data)
         {
             Console.WriteLine($"Объект {i}");
         }
     }
 }