Add RomCenter internal converters

This commit is contained in:
Matt Nadareski
2023-08-04 21:02:29 -04:00
parent c62f6e0004
commit eef1dcb828
2 changed files with 38 additions and 0 deletions

View File

@@ -1310,5 +1310,24 @@ namespace SabreTools.Serialization
}
#endregion
#region RomCenter
/// <summary>
/// Convert from <cref="Models.RomCenter.Rom"/> to <cref="Models.Internal.Rom"/>
/// </summary>
public static Models.Internal.Rom ConvertFromRomCenter(Models.RomCenter.Rom item)
{
var rom = new Models.Internal.Rom
{
[Models.Internal.Rom.NameKey] = item.RomName,
[Models.Internal.Rom.CRCKey] = item.RomCRC,
[Models.Internal.Rom.SizeKey] = item.RomSize,
[Models.Internal.Rom.MergeKey] = item.MergeName,
};
return rom;
}
#endregion
}
}