Пример #1
0
        internal static Player Create(long facebookID)
        {
            PolarTicTacToeDataContext dataContext = new PolarTicTacToeDataContext();

            Player newPlayer = new Player();

            newPlayer.FacebookID = facebookID;

            dataContext.Players.InsertOnSubmit(newPlayer);

            dataContext.SubmitChanges();

            return newPlayer;
        }
Пример #2
0
        internal static Player Create(long facebookID, string firstName, string lastName)
        {
            PolarTicTacToeDataContext dataContext = new PolarTicTacToeDataContext();

            Player newPlayer = new Player();

            newPlayer.FacebookID = facebookID;
            newPlayer.FirstName = firstName;
            newPlayer.LastName = lastName;

            dataContext.Players.InsertOnSubmit(newPlayer);

            dataContext.SubmitChanges();

            return newPlayer;
        }
 partial void UpdatePlayer(Player instance);
 partial void DeletePlayer(Player instance);
 partial void InsertPlayer(Player instance);