示例#1
0
        private void AddMagicBoxGroup(List<MagicBoxOrder> mgcBoxOrderList, IGrouping<DateTime, EconomicEvent> eventGroup)
        {
            // refactor the this events

            var currencyPairsCandidate = new List<MagicBoxOrder>();

            foreach (var economicEvent in eventGroup.Distinct())
            {
                currencyPairsCandidate.Add(new MagicBoxOrder
                {
                    Symbol = economicEvent.Currency,
                    LotSize = 1,
                    Config = speechCfg,
                    NewsTime = economicEvent.DateTime
                });
            }

            mgcBoxOrderList.AddRange(currencyPairsCandidate.Distinct());
        }
示例#2
0
        private void AddMagicBoxGroup(List <MagicBoxOrder> mgcBoxOrderList, IGrouping <DateTime, EconomicEvent> eventGroup)
        {
            // refactor the this events

            var currencyPairsCandidate = new List <MagicBoxOrder>();

            foreach (EconomicEvent economicEvent in eventGroup.Distinct())
            {
                currencyPairsCandidate.Add(new MagicBoxOrder
                {
                    Symbol   = economicEvent.Currency,
                    LotSize  = 1,
                    Config   = speechCfg,
                    NewsTime = economicEvent.DateTime
                });
            }

            mgcBoxOrderList.AddRange(currencyPairsCandidate.Distinct());
        }
示例#3
0
 private int CountRowsBelow <T> (IGrouping <T, AclExpansionEntry> grouping)
 {
     return(grouping.Distinct(AclExpansionEntryIgnoreStateEqualityComparer).Count());
 }