mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Parsing to actual class
This commit is contained in:
@@ -450,7 +450,7 @@ namespace SabreTools.DatFiles
|
||||
var input = inputs[i];
|
||||
logger.User($"Adding DAT: {input.CurrentPath}");
|
||||
datFiles[i] = DatFile.Create(datFile.Header.CloneFiltering());
|
||||
ParseInto(datFiles[i], input, i, keep: true);
|
||||
Parser.ParseInto(datFiles[i], input, i, keep: true);
|
||||
});
|
||||
|
||||
watch.Stop();
|
||||
|
||||
@@ -1425,7 +1425,7 @@ namespace SabreTools.DatFiles
|
||||
|
||||
staticLogger.Verbose($"Beginning stat collection for '{file.CurrentPath}'");
|
||||
List<string> games = new List<string>();
|
||||
DatFile datdata = DatTool.CreateAndParse(file.CurrentPath);
|
||||
DatFile datdata = Parser.CreateAndParse(file.CurrentPath);
|
||||
datdata.Items.BucketBy(Field.Machine_Name, DedupeType.None, norename: true);
|
||||
|
||||
// Output single DAT stats (if asked)
|
||||
|
||||
@@ -4,12 +4,22 @@ using System.Text.RegularExpressions;
|
||||
|
||||
using SabreTools.Core;
|
||||
using SabreTools.IO;
|
||||
using SabreTools.Logging;
|
||||
|
||||
// This file represents all methods related to parsing from a file
|
||||
namespace SabreTools.DatFiles
|
||||
{
|
||||
public partial class DatTool
|
||||
public class Parser
|
||||
{
|
||||
#region Logging
|
||||
|
||||
/// <summary>
|
||||
/// Logging object
|
||||
/// </summary>
|
||||
private static readonly Logger logger = new Logger();
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// Create a DatFile and parse a file into it
|
||||
/// </summary>
|
||||
Reference in New Issue
Block a user