22 lines
549 B
C#
22 lines
549 B
C#
using Newtonsoft.Json;
|
|
|
|
namespace ModpackUpdater;
|
|
|
|
public class UpdateInfos
|
|
{
|
|
public List<UpdateInfo> Updates { get; private set; } = [];
|
|
|
|
public static UpdateInfos Parse(string content)
|
|
{
|
|
return JsonConvert.DeserializeObject<UpdateInfos>(content);
|
|
}
|
|
|
|
public override string ToString()
|
|
{
|
|
return JsonConvert.SerializeObject(this, new JsonSerializerSettings
|
|
{
|
|
Formatting = Formatting.Indented,
|
|
DefaultValueHandling = DefaultValueHandling.IgnoreAndPopulate,
|
|
});
|
|
}
|
|
} |