using System.Collections.Generic; using System.Linq; namespace StardewModdingAPI.Web.ViewModels { /// Metadata for the mod list page. public class ModListModel { /********* ** Accessors *********/ /// The current stable version of the game. public string StableVersion { get; set; } /// The current beta version of the game (if any). public string BetaVersion { get; set; } /// The mods to display. public ModModel[] Mods { get; set; } /********* ** Public methods *********/ /// Construct an instance. /// The current stable version of the game. /// The current beta version of the game (if any). /// The mods to display. public ModListModel(string stableVersion, string betaVersion, IEnumerable mods) { this.StableVersion = stableVersion; this.BetaVersion = betaVersion; this.Mods = mods.ToArray(); } } }