summaryrefslogtreecommitdiff
path: root/src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2022-04-12 19:15:39 -0400
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2022-04-12 19:15:39 -0400
commit0b48c1748b354458059c7607415288de072b01e9 (patch)
treef63fd950f565d363414eb692be9024895cdea174 /src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs
parent9fbed0fa1f28a9b0fe0b952a78b10e2d475adb03 (diff)
downloadSMAPI-0b48c1748b354458059c7607415288de072b01e9.tar.gz
SMAPI-0b48c1748b354458059c7607415288de072b01e9.tar.bz2
SMAPI-0b48c1748b354458059c7607415288de072b01e9.zip
enable nullable annotations in the web project & related code (#837)
Diffstat (limited to 'src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs')
-rw-r--r--src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs b/src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs
index 1787197a..24548078 100644
--- a/src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs
+++ b/src/SMAPI.Toolkit/Framework/Clients/Wiki/WikiModList.cs
@@ -1,5 +1,3 @@
-#nullable disable
-
namespace StardewModdingAPI.Toolkit.Framework.Clients.Wiki
{
/// <summary>Metadata from the wiki's mod compatibility list.</summary>
@@ -9,12 +7,27 @@ namespace StardewModdingAPI.Toolkit.Framework.Clients.Wiki
** Accessors
*********/
/// <summary>The stable game version.</summary>
- public string StableVersion { get; set; }
+ public string? StableVersion { get; }
/// <summary>The beta game version (if any).</summary>
- public string BetaVersion { get; set; }
+ public string? BetaVersion { get; }
/// <summary>The mods on the wiki.</summary>
- public WikiModEntry[] Mods { get; set; }
+ public WikiModEntry[] Mods { get; }
+
+
+ /*********
+ ** Public methods
+ *********/
+ /// <summary>Construct an instance.</summary>
+ /// <param name="stableVersion">The stable game version.</param>
+ /// <param name="betaVersion">The beta game version (if any).</param>
+ /// <param name="mods">The mods on the wiki.</param>
+ public WikiModList(string? stableVersion, string? betaVersion, WikiModEntry[] mods)
+ {
+ this.StableVersion = stableVersion;
+ this.BetaVersion = betaVersion;
+ this.Mods = mods;
+ }
}
}