/// <summary> /// Creates a copy of the specified report. /// </summary> /// <param name="report">The report to copy from.</param> /// <returns>The copied report.</returns> /// <remarks> /// If <paramref name="report" /> is a null reference, a standard new instance is returned. /// </remarks> public static Report CreateCopyOf(Report report) { return (report == null) ? new Report() : new Report { Equipment = report.Equipment, EquipmentId = report.EquipmentId, LandTransport = report.LandTransport, LandTransportId = report.LandTransportId, Experience = report.Experience, Kills = report.Kills, Losses = report.Losses, HighestAward = report.HighestAward, FirstHero = report.FirstHero, SecondHero = report.SecondHero, ThirdHero = report.ThirdHero }; }
/// <summary> /// Adds an after action report to the end of the list of this unit's AARs. /// </summary> /// <param name="report">The after action report to add.</param> /// <exception cref="ArgumentNullException">When report is null.</exception> public virtual void AddNewReport(Report report) { Contract.Requires<ArgumentNullException>(report != null); this._reports.Add(report); }