diff options
Diffstat (limited to 'src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels')
4 files changed, 59 insertions, 0 deletions
diff --git a/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/FileDataModel.cs b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/FileDataModel.cs new file mode 100644 index 00000000..fa84b287 --- /dev/null +++ b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/FileDataModel.cs @@ -0,0 +1,21 @@ +namespace StardewModdingAPI.Web.Framework.Clients.ModDrop.ResponseModels +{ + /// <summary>Metadata from the ModDrop API about a mod file.</summary> + public class FileDataModel + { + /// <summary>Whether the file is deleted.</summary> + public bool IsDeleted { get; set; } + + /// <summary>Whether the file is hidden from users.</summary> + public bool IsHidden { get; set; } + + /// <summary>Whether this is the default file for the mod.</summary> + public bool IsDefault { get; set; } + + /// <summary>Whether this is an archived file.</summary> + public bool IsOld { get; set; } + + /// <summary>The file version.</summary> + public string Version { get; set; } + } +} diff --git a/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModDataModel.cs b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModDataModel.cs new file mode 100644 index 00000000..cfdd6a4e --- /dev/null +++ b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModDataModel.cs @@ -0,0 +1,15 @@ +namespace StardewModdingAPI.Web.Framework.Clients.ModDrop.ResponseModels +{ + /// <summary>Metadata about a mod from the ModDrop API.</summary> + public class ModDataModel + { + /// <summary>The mod's unique ID on ModDrop.</summary> + public int ID { get; set; } + + /// <summary>The error code, if any.</summary> + public int? ErrorCode { get; set; } + + /// <summary>The mod name.</summary> + public string Title { get; set; } + } +} diff --git a/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModListModel.cs b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModListModel.cs new file mode 100644 index 00000000..7f692ca1 --- /dev/null +++ b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModListModel.cs @@ -0,0 +1,11 @@ +using System.Collections.Generic; + +namespace StardewModdingAPI.Web.Framework.Clients.ModDrop.ResponseModels +{ + /// <summary>A list of mods from the ModDrop API.</summary> + public class ModListModel + { + /// <summary>The mod data.</summary> + public IDictionary<long, ModModel> Mods { get; set; } + } +} diff --git a/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModModel.cs b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModModel.cs new file mode 100644 index 00000000..9f4b2c6f --- /dev/null +++ b/src/SMAPI.Web/Framework/Clients/ModDrop/ResponseModels/ModModel.cs @@ -0,0 +1,12 @@ +namespace StardewModdingAPI.Web.Framework.Clients.ModDrop.ResponseModels +{ + /// <summary>An entry in a mod list from the ModDrop API.</summary> + public class ModModel + { + /// <summary>The available file downloads.</summary> + public FileDataModel[] Files { get; set; } + + /// <summary>The mod metadata.</summary> + public ModDataModel Mod { get; set; } + } +} |