Example #1
0
 public Biblioteka(Obslugatxt obsugatxt, Obslugajson obslugajson, Obslugaxml obslugaxml)
 {
     Obslugatxt   = obsugatxt;
     Obslugajson  = obslugajson;
     Obslugaxml   = obslugaxml;
     ListaKsiazek = new List <Ksiazka>();
 }
Example #2
0
        static void Main(string[] args)
        {
            Obslugatxt  obslugatxt  = new Obslugatxt();
            Obslugajson obslugajson = new Obslugajson();
            Obslugaxml  obslugaxml  = new Obslugaxml();
            Biblioteka  biblioteka  = new Biblioteka(obslugatxt, obslugajson, obslugaxml);

            biblioteka.Read();
            biblioteka.WybierzAkcje();
        }
Example #3
0
        static void Main(string[] args)
        {
            Obslugatxt  obslugatxt  = new Obslugatxt();
            Obslugajson obslugajson = new Obslugajson();
            Obslugaxml  obslugaxml  = new Obslugaxml();
            Biblioteka  biblioteka  = new Biblioteka(obslugatxt, obslugajson, obslugaxml);

            //blioteka.Write();
            biblioteka.Read();
            biblioteka.WybierzAkcje();
            //string path = AppDomain.CurrentDomain.BaseDirectory;
            //string path = Path.Combine(Environment.CurrentDirectory,"danetxt.txt");
            //Console.WriteLine(path);



            Console.ReadLine();
        }
Example #4
0
 private void Update(Ksiazka ksiazka)
 {
     Obslugaxml.Update(ksiazka);
     Obslugatxt.Update(ksiazka);
     Obslugajson.Update(ksiazka);
 }
Example #5
0
 private void Remove(int id)
 {
     Obslugatxt.Remove(id);
     Obslugajson.Remove(id);
     Obslugaxml.Remove(id);
 }
Example #6
0
 private void Add(Ksiazka ksiazka)
 {
     Obslugatxt.Add(ksiazka);
     Obslugajson.Add(ksiazka);
     Obslugaxml.Add(ksiazka);
 }
Example #7
0
 public void Write()
 {
     Obslugajson.Write(ListaKsiazek);
     Obslugatxt.Write(ListaKsiazek);
     Obslugaxml.Write(ListaKsiazek);
 }
Example #8
0
 public Biblioteka(Obslugatxt obsugatxt, Obslugajson obslugajson, Obslugaxml obslugaxml)
 {
     Obslugatxt  = obsugatxt;
     Obslugajson = obslugajson;
     Obslugaxml  = obslugaxml;
 }