예제 #1
0
            public MapContainer(string mapname, IEnumerable <ReplayInfo> tanks)
            {
                MapName         = mapname;
                TanksContainers = tanks.GroupBy(x => x.Tank, (tankname, replays) => new TankContainer(tankname, replays)).ToList();

                if (ReportInformation.SortBy == ReportInformation.SortMethod.AverageDamage)
                {
                    TanksContainers.Sort((x, y) => y.AverageDamage - x.AverageDamage);
                }
                if (ReportInformation.SortBy == ReportInformation.SortMethod.BattlesCount)
                {
                    TanksContainers.Sort((x, y) => y.BattlesCount - x.BattlesCount);
                }
            }
예제 #2
0
 public IEnumerator <TankContainer> GetEnumerator()
 {
     return(TanksContainers.GetEnumerator());
 }