Ejemplo n.º 1
0
 //----------------------------------------------------
 //Update Aircraft
 public static void updateAircraft(Aircraft aircraft, Aircraft newValues)
 {
     aircraft.aircraftOwner_id = newValues.aircraftOwner_id;
     aircraft.aircraft_number = newValues.aircraft_number;
     aircraft.aircraft_ton = newValues.aircraft_ton;
     aircraft.aircraftType_code = newValues.aircraftType_code;
     DbConn.CONN.SaveChanges();
 }
Ejemplo n.º 2
0
 //-------------------------------------------------------------------------------
 static object aircraftToObject(Aircraft aircraft)
 {
     return new
     {
         aircraft_id = aircraft.aircraft_id,
         aircraft_number = aircraft.aircraft_number,
         aircraftOwner_id = aircraft.aircraftOwner_id,
         aircraft_ton = aircraft.aircraft_ton,
         aircraftType_code = aircraft.aircraftType_code
     };
 }
Ejemplo n.º 3
0
 //----------------------------------------------------
 //Create Aircraft
 public static void createAircraft(Aircraft aircraft)
 {
     DbConn.CONN.Aircraft.AddObject(aircraft);
     DbConn.CONN.SaveChanges();
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Créez un nouvel objet Aircraft.
 /// </summary>
 /// <param name="aircraft_id">Valeur initiale de la propriété aircraft_id.</param>
 public static Aircraft CreateAircraft(global::System.Int64 aircraft_id)
 {
     Aircraft aircraft = new Aircraft();
     aircraft.aircraft_id = aircraft_id;
     return aircraft;
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Méthode déconseillée pour ajouter un nouvel objet à l'EntitySet Aircraft. Utilisez la méthode .Add de la propriété ObjectSet&lt;T&gt; associée à la place.
 /// </summary>
 public void AddToAircraft(Aircraft aircraft)
 {
     base.AddObject("Aircraft", aircraft);
 }