public Dictionary <object, object> toJSON() { var _event = new Dictionary <object, object>(); _event.Add("eventID", EventId); _event.Add("competitionType", CompetitionType); _event.Add("competitionName", Team1.getName() + " vs " + Team2.getName()); _event.Add("currentResult", Team1.getScore() + " : " + Team2.getScore()); return(_event); }
public override string ToString() { var result = new StringBuilder(); result.AppendLine("======Event:" + EventId + "=========="); result.AppendLine("Compitition name: " + CompetitionType); result.AppendLine("Player1: " + Team1.getName() + " Player 2" + Team2.getName()); result.AppendLine("Score: " + Team1.getScore() + ":" + Team2.getScore()); return(result.ToString()); }