Beispiel #1
0
        public override void MergeData(QueryableObject obj)
        {
            Match match = obj as Match;
            if (match == null)
            {
                return;
            }

            if (match.LastQueryTimestamp > LastQueryTimestamp)
            {
                ResultBase64 = match.ResultBase64;
            }

            LastQueryTimestamp = Math.Max(match.LastQueryTimestamp, LastQueryTimestamp);
        }
Beispiel #2
0
        public override void MergeData(QueryableObject obj)
        {
            Player player = obj as Player;
            if (player == null)
            {
                return;
            }

            LastQueryTimestamp = Math.Max(player.LastQueryTimestamp, LastQueryTimestamp);

            foreach (MatchID id in player.MatchsIds)
            {
                MatchID firstId = MatchsIds.FirstOrDefault(m => m.Id == id.Id);
                if (firstId == null)
                {
                    MatchsIds.Add(id);
                }
                else
                {
                    firstId.MergeData(id);
                }
            }
        }
 public abstract void MergeData(QueryableObject obj);