mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Create Required attribute and tag properties
This commit is contained in:
@@ -6,11 +6,13 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("dataarea")]
|
||||
public class DataArea
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlAttribute("size")]
|
||||
public string Size { get; set; }
|
||||
public string? Size { get; set; }
|
||||
|
||||
/// <remarks>(8|16|32|64) "8"</remarks>
|
||||
[XmlAttribute("width")]
|
||||
|
||||
@@ -6,11 +6,13 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("dipswitch")]
|
||||
public class DipSwitch
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlAttribute("tag")]
|
||||
public string Tag { get; set; }
|
||||
public string? Tag { get; set; }
|
||||
|
||||
[XmlAttribute("mask")]
|
||||
public string? Mask { get; set; }
|
||||
|
||||
@@ -6,11 +6,13 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("dipvalue")]
|
||||
public class DipValue
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlAttribute("value")]
|
||||
public string Value { get; set; }
|
||||
public string? Value { get; set; }
|
||||
|
||||
/// <remarks>(yes|no) "no"</remarks>
|
||||
[XmlAttribute("default")]
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("disk")]
|
||||
public class Disk
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("md5")]
|
||||
public string? MD5 { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("diskarea")]
|
||||
public class DiskArea
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlElement("disk")]
|
||||
public Disk[]? Disk { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("feature")]
|
||||
public class Feature
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("value")]
|
||||
public string? Value { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("info")]
|
||||
public class Info
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("value")]
|
||||
public string? Value { get; set; }
|
||||
|
||||
@@ -6,11 +6,13 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("part")]
|
||||
public class Part
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlAttribute("interface")]
|
||||
public string Interface { get; set; }
|
||||
public string? Interface { get; set; }
|
||||
|
||||
[XmlElement("feature")]
|
||||
public Feature[]? Feature { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("rom")]
|
||||
public class Rom
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("size")]
|
||||
public string? Size { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("sharedfeat")]
|
||||
public class SharedFeat
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("value")]
|
||||
public string? Value { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("software")]
|
||||
public class Software
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("cloneof")]
|
||||
public string? CloneOf { get; set; }
|
||||
@@ -16,14 +17,17 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlAttribute("supported")]
|
||||
public string? Supported { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlElement("description")]
|
||||
public string Description { get; set; }
|
||||
public string? Description { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlElement("year")]
|
||||
public string Year { get; set; }
|
||||
public string? Year { get; set; }
|
||||
|
||||
[Required]
|
||||
[XmlElement("publisher")]
|
||||
public string Publisher { get; set; }
|
||||
public string? Publisher { get; set; }
|
||||
|
||||
[XmlElement("notes")]
|
||||
public string? Notes { get; set; }
|
||||
|
||||
@@ -6,8 +6,9 @@ namespace SabreTools.Models.SoftwareList
|
||||
[XmlRoot("softwarelist")]
|
||||
public class SoftwareList
|
||||
{
|
||||
[Required]
|
||||
[XmlAttribute("name")]
|
||||
public string Name { get; set; }
|
||||
public string? Name { get; set; }
|
||||
|
||||
[XmlAttribute("description")]
|
||||
public string? Description { get; set; }
|
||||
@@ -16,7 +17,7 @@ namespace SabreTools.Models.SoftwareList
|
||||
public string? Notes { get; set; }
|
||||
|
||||
[XmlElement("software")]
|
||||
public Software[] Software { get; set; }
|
||||
public Software[]? Software { get; set; }
|
||||
|
||||
#region DO NOT USE IN PRODUCTION
|
||||
|
||||
|
||||
Reference in New Issue
Block a user