summaryrefslogtreecommitdiff
path: root/src/SMAPI.Web/ViewModels/IndexModel.cs
blob: 4268c878a084054c5476267abb57e8335ad11afb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
namespace StardewModdingAPI.Web.ViewModels
{
    /// <summary>The view model for the index page.</summary>
    public class IndexModel
    {
        /*********
        ** Accessors
        *********/
        /// <summary>The latest stable SMAPI version.</summary>
        public IndexVersionModel StableVersion { get; set; }

        /// <summary>The latest prerelease SMAPI version (if newer than <see cref="StableVersion"/>).</summary>
        public IndexVersionModel BetaVersion { get; set; }


        /*********
        ** Public methods
        *********/
        /// <summary>Construct an instance.</summary>
        public IndexModel() { }

        /// <summary>Construct an instance.</summary>
        /// <param name="stableVersion">The latest stable SMAPI version.</param>
        /// <param name="betaVersion">The latest prerelease SMAPI version (if newer than <paramref name="stableVersion"/>).</param>
        internal IndexModel(IndexVersionModel stableVersion, IndexVersionModel betaVersion)
        {
            this.StableVersion = stableVersion;
            this.BetaVersion = betaVersion;
        }
    }
}