예제 #1
0
        public IRepository InsertHands(IEnumerable <IConvertedPokerHand> handsToInsert)
        {
            Action <IStatelessSession> insertHands = statelessSession => {
                foreach (IConvertedPokerHand convertedHand in handsToInsert)
                {
                    try
                    {
                        _pokerHandDao.Insert(convertedHand, statelessSession);
                    }
                    catch (Exception excep)
                    {
                        Log.Error(excep);
                    }
                }
            };

            _transactionManager.BatchExecute(insertHands);

            return(this);
        }