Files
SabreTools/SabreTools.DatItems/Formats/BiosSet.cs

34 lines
923 B
C#
Raw Normal View History

using System.Xml.Serialization;
2020-08-23 22:23:55 -07:00
using Newtonsoft.Json;
using SabreTools.Core.Tools;
2016-10-12 16:02:51 -07:00
2021-02-02 10:23:43 -08:00
namespace SabreTools.DatItems.Formats
{
2019-01-08 17:40:12 -08:00
/// <summary>
/// Represents which BIOS(es) is associated with a set
/// </summary>
2020-09-08 10:12:41 -07:00
[JsonObject("biosset"), XmlRoot("biosset")]
2024-03-10 20:39:54 -04:00
public sealed class BiosSet : DatItem<Models.Metadata.BiosSet>
2019-01-08 17:40:12 -08:00
{
2024-03-10 20:39:54 -04:00
#region Fields
2020-08-17 17:28:32 -07:00
2024-03-10 20:39:54 -04:00
/// <inheritdoc>/>
protected override ItemType ItemType => ItemType.BiosSet;
2020-09-02 12:19:12 -07:00
2020-08-17 17:28:32 -07:00
#endregion
2019-01-08 17:40:12 -08:00
#region Constructors
2024-03-10 20:39:54 -04:00
public BiosSet() : base() { }
public BiosSet(Models.Metadata.BiosSet item) : base(item)
{
// Process flag values
if (GetBoolFieldValue(Models.Metadata.BiosSet.DefaultKey) != null)
SetFieldValue<string?>(Models.Metadata.BiosSet.DefaultKey, GetBoolFieldValue(Models.Metadata.BiosSet.DefaultKey).FromYesNo());
}
2019-01-08 17:40:12 -08:00
#endregion
}
}