Пример #1
0
 public Car(Pilot pilot, string name)
 {
     this.pilot = pilot;
     this.name = name;
 }
Пример #2
0
 public Car(Pilot pilot, string name)
 {
     this.pilot = pilot;
     this.name  = name;
 }
Пример #3
0
     private static void StoreObjectsIn(string databaseFile)
     {
         using (IObjectContainer container = OpenDatabase(databaseFile)){
             Pilot john = new Pilot("John", 100);
             Car johnsCar = new Car(john, "John's Car");
             container.Store(johnsCar);
             Pilot max = new Pilot("Max", 200);
             Car maxsCar = new Car(max, "Max's Car");
             container.Store(maxsCar);
             container.Commit();
         }
 }