summaryrefslogtreecommitdiff
path: root/src/StardewModdingAPI.Models/ModSeachModel.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/StardewModdingAPI.Models/ModSeachModel.cs')
-rw-r--r--src/StardewModdingAPI.Models/ModSeachModel.cs30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/StardewModdingAPI.Models/ModSeachModel.cs b/src/StardewModdingAPI.Models/ModSeachModel.cs
new file mode 100644
index 00000000..526fbaf3
--- /dev/null
+++ b/src/StardewModdingAPI.Models/ModSeachModel.cs
@@ -0,0 +1,30 @@
+using System.Collections.Generic;
+using System.Linq;
+
+namespace StardewModdingAPI.Models
+{
+ /// <summary>Specifies mods whose update-check info to fetch.</summary>
+ internal class ModSearchModel
+ {
+ /*********
+ ** Accessors
+ *********/
+ /// <summary>The namespaced mod keys to search.</summary>
+ public string[] ModKeys { get; set; }
+
+
+ /*********
+ ** Public methods
+ *********/
+ /// <summary>Construct an empty instance.</summary>
+ /// <remarks>This constructed is needed for JSON deserialisation.</remarks>
+ public ModSearchModel() { }
+
+ /// <summary>Construct an valid instance.</summary>
+ /// <param name="modKeys">The namespaced mod keys to search.</param>
+ public ModSearchModel(IEnumerable<string> modKeys)
+ {
+ this.ModKeys = modKeys.ToArray();
+ }
+ }
+}