LootDumpProcessor/Storage/AbstractKey.cs

29 lines
605 B
C#
Raw Normal View History

2023-08-12 19:08:38 +01:00
using System.Text.Json.Serialization;
using Newtonsoft.Json;
namespace LootDumpProcessor.Storage;
public abstract class AbstractKey : IKey
{
public abstract KeyType GetKeyType();
private string[] indexes;
[JsonProperty("serializedKey")]
[JsonPropertyName("serializedKey")]
public string SerializedKey
{
get { return string.Join("|", this.indexes); }
set { indexes = value.Split("|"); }
}
public AbstractKey(string[] indexes)
{
this.indexes = indexes;
}
public string[] GetLookupIndex()
{
return this.indexes;
}
}