예제 #1
0
        public Board Get()
        {
            Board board = default(Board);
            board = this.session.Load<Board>(Board.BoardId);

            if (board == null)
            {
                board = new Board();
                this.session.Store(board);
                this.session.SaveChanges();
            }

            return board;
        }
예제 #2
0
 public void Save(Board board)
 {
     this.session.Store(board);
     this.session.SaveChanges();
 }