/// <summary> /// Create a new Session object. /// </summary> /// <param name="dateAdded">Initial value of the DateAdded property.</param> /// <param name="id">Initial value of the ID property.</param> public static Session CreateSession(global::System.DateTime dateAdded, global::System.Guid id) { Session session = new Session(); session.DateAdded = dateAdded; session.ID = id; return session; }
public void CreateSession(DateTime date) { _session = new Session { DateAdded = date }; _repo.Sessions.AddObject(_session); _repo.SaveChanges(); }
/// <summary> /// Deprecated Method for adding a new object to the Sessions EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// </summary> public void AddToSessions(Session session) { base.AddObject("Sessions", session); }