namespace StardewModdingAPI.Toolkit.Framework.Clients.WebApi { /// Specifies the identifiers for a mod to match. public class ModSearchEntryModel { /********* ** Accessors *********/ /// The unique mod ID. public string ID { get; set; } /// The namespaced mod update keys (if available). public string[] UpdateKeys { get; set; } /// The mod version installed by the local player. This is used for version mapping in some cases. public ISemanticVersion InstalledVersion { get; set; } /// Whether the installed version is broken or could not be loaded. public bool IsBroken { get; set; } /********* ** Public methods *********/ /// Construct an empty instance. public ModSearchEntryModel() { // needed for JSON deserializing } /// Construct an instance. /// The unique mod ID. /// The version installed by the local player. This is used for version mapping in some cases. /// The namespaced mod update keys (if available). /// Whether the installed version is broken or could not be loaded. public ModSearchEntryModel(string id, ISemanticVersion installedVersion, string[] updateKeys, bool isBroken = false) { this.ID = id; this.InstalledVersion = installedVersion; this.UpdateKeys = updateKeys ?? new string[0]; } } }