mirror of
https://github.com/4sval/FModel.git
synced 2026-09-26 11:07:39 -05:00
FModel 2.2
This commit is contained in:
73
FModel/Parser/Banners/BannersParser.cs
Normal file
73
FModel/Parser/Banners/BannersParser.cs
Normal file
@@ -0,0 +1,73 @@
|
||||
// <auto-generated />
|
||||
//
|
||||
// To parse this JSON data, add NuGet 'Newtonsoft.Json' then do:
|
||||
//
|
||||
// using FModel.Parser.Banners;
|
||||
//
|
||||
// var bannersParser = BannersParser.FromJson(jsonString);
|
||||
|
||||
namespace FModel.Parser.Banners
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using System.Globalization;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Converters;
|
||||
|
||||
public partial class BannersParser
|
||||
{
|
||||
[JsonProperty("export_type")]
|
||||
public string ExportType { get; set; }
|
||||
|
||||
[JsonProperty("SmallImage")]
|
||||
public Image SmallImage { get; set; }
|
||||
|
||||
[JsonProperty("LargeImage")]
|
||||
public Image LargeImage { get; set; }
|
||||
|
||||
[JsonProperty("CategoryRowName")]
|
||||
public string CategoryRowName { get; set; }
|
||||
|
||||
[JsonProperty("DisplayName")]
|
||||
public string DisplayName { get; set; }
|
||||
|
||||
[JsonProperty("DisplayDescription")]
|
||||
public string DisplayDescription { get; set; }
|
||||
|
||||
[JsonProperty("bFullUsageRights")]
|
||||
public bool BFullUsageRights { get; set; }
|
||||
}
|
||||
|
||||
public partial class Image
|
||||
{
|
||||
[JsonProperty("asset_path_name")]
|
||||
public string AssetPathName { get; set; }
|
||||
|
||||
[JsonProperty("sub_path_string")]
|
||||
public string SubPathString { get; set; }
|
||||
}
|
||||
|
||||
public partial class BannersParser
|
||||
{
|
||||
public static BannersParser FromJson(string json) => JsonConvert.DeserializeObject<BannersParser>(json, FModel.Parser.Banners.Converter.Settings);
|
||||
}
|
||||
|
||||
public static class Serialize
|
||||
{
|
||||
public static string ToJson(this BannersParser self) => JsonConvert.SerializeObject(self, FModel.Parser.Banners.Converter.Settings);
|
||||
}
|
||||
|
||||
internal static class Converter
|
||||
{
|
||||
public static readonly JsonSerializerSettings Settings = new JsonSerializerSettings
|
||||
{
|
||||
MetadataPropertyHandling = MetadataPropertyHandling.Ignore,
|
||||
DateParseHandling = DateParseHandling.None,
|
||||
Converters =
|
||||
{
|
||||
new IsoDateTimeConverter { DateTimeStyles = DateTimeStyles.AssumeUniversal }
|
||||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user