namespace StardewModdingAPI.Framework.Models
{
/// A mod dependency listed in a mod manifest.
internal class ManifestDependency : IManifestDependency
{
/*********
** Accessors
*********/
/// The unique mod ID to require.
public string UniqueID { get; set; }
/// The minimum required version (if any).
public ISemanticVersion MinimumVersion { get; set; }
/*********
** Public methods
*********/
/// Construct an instance.
/// The unique mod ID to require.
/// The minimum required version (if any).
public ManifestDependency(string uniqueID, string minimumVersion)
{
this.UniqueID = uniqueID;
this.MinimumVersion = !string.IsNullOrWhiteSpace(minimumVersion)
? new SemanticVersion(minimumVersion)
: null;
}
}
}