mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
[DatFile] Add temporary code to write SL and OL to XML
This commit is contained in:
@@ -3370,6 +3370,8 @@ namespace SabreTools.Helper
|
|||||||
"\t<data>\n";
|
"\t<data>\n";
|
||||||
break;
|
break;
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
header = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
|
header = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
|
||||||
"<!DOCTYPE datafile PUBLIC \"-//Logiqx//DTD ROM Management Datafile//EN\" \"http://www.logiqx.com/Dats/datafile.dtd\">\n\n" +
|
"<!DOCTYPE datafile PUBLIC \"-//Logiqx//DTD ROM Management Datafile//EN\" \"http://www.logiqx.com/Dats/datafile.dtd\">\n\n" +
|
||||||
"<datafile>\n" +
|
"<datafile>\n" +
|
||||||
@@ -3463,6 +3465,8 @@ namespace SabreTools.Helper
|
|||||||
depth = depth - (last == -1 ? 0 : last) + newsplit.Count;
|
depth = depth - (last == -1 ? 0 : last) + newsplit.Count;
|
||||||
break;
|
break;
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
state += "\t<machine name=\"" + HttpUtility.HtmlEncode(rom.MachineName) + "\"" +
|
state += "\t<machine name=\"" + HttpUtility.HtmlEncode(rom.MachineName) + "\"" +
|
||||||
(rom.IsBios ? " isbios=\"yes\"" : "") +
|
(rom.IsBios ? " isbios=\"yes\"" : "") +
|
||||||
(String.IsNullOrEmpty(rom.CloneOf) ? "" : " cloneof=\"" + HttpUtility.HtmlEncode(rom.CloneOf) + "\"") +
|
(String.IsNullOrEmpty(rom.CloneOf) ? "" : " cloneof=\"" + HttpUtility.HtmlEncode(rom.CloneOf) + "\"") +
|
||||||
@@ -3546,6 +3550,8 @@ namespace SabreTools.Helper
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
state += "\t</machine>\n";
|
state += "\t</machine>\n";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -3912,6 +3918,8 @@ namespace SabreTools.Helper
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
switch (rom.Type)
|
switch (rom.Type)
|
||||||
{
|
{
|
||||||
case ItemType.Archive:
|
case ItemType.Archive:
|
||||||
@@ -4009,6 +4017,8 @@ namespace SabreTools.Helper
|
|||||||
footer += "\t</data>\n</datafile>\n";
|
footer += "\t</data>\n</datafile>\n";
|
||||||
break;
|
break;
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
footer = "\t</machine>\n</datafile>\n";
|
footer = "\t</machine>\n</datafile>\n";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -4021,6 +4031,8 @@ namespace SabreTools.Helper
|
|||||||
{
|
{
|
||||||
case OutputFormat.SabreDat:
|
case OutputFormat.SabreDat:
|
||||||
case OutputFormat.Xml:
|
case OutputFormat.Xml:
|
||||||
|
case OutputFormat.SoftwareList:
|
||||||
|
case OutputFormat.OfflineList:
|
||||||
footer = "</datafile>\n";
|
footer = "</datafile>\n";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user