mirror of
https://github.com/sp-tarkov/loot-dump-processor.git
synced 2025-02-13 09:50:44 -05:00
Removed unused GetAll method from storage interfaces and implementations
This commit is contained in:
parent
4003ca254b
commit
e52a8b2fad
@ -1,16 +1,14 @@
|
|||||||
|
using System.Text.Json.Serialization;
|
||||||
using LootDumpProcessor.Serializers.Json.Converters;
|
using LootDumpProcessor.Serializers.Json.Converters;
|
||||||
using LootDumpProcessor.Storage;
|
using LootDumpProcessor.Storage;
|
||||||
|
|
||||||
namespace LootDumpProcessor.Model.Processing;
|
namespace LootDumpProcessor.Model.Processing;
|
||||||
|
|
||||||
public class PreProcessedLooseLoot : IKeyable
|
public class PreProcessedLooseLoot
|
||||||
{
|
{
|
||||||
public Dictionary<string, int> Counts { get; set; }
|
public Dictionary<string, int> Counts { get; set; }
|
||||||
|
|
||||||
[System.Text.Json.Serialization.JsonConverter(typeof(NetJsonKeyConverter))]
|
[JsonConverter(typeof(NetJsonKeyConverter))] public IKey ItemProperties { get; set; }
|
||||||
public IKey ItemProperties { get; set; }
|
|
||||||
|
|
||||||
public int MapSpawnpointCount { get; set; }
|
public int MapSpawnpointCount { get; set; }
|
||||||
|
|
||||||
public IKey GetKey() => throw new NotImplementedException();
|
|
||||||
}
|
}
|
@ -6,6 +6,5 @@ public interface IDataStorage
|
|||||||
void Store<T>(T t) where T : IKeyable;
|
void Store<T>(T t) where T : IKeyable;
|
||||||
bool Exists(IKey t);
|
bool Exists(IKey t);
|
||||||
T GetItem<T>(IKey key) where T : IKeyable;
|
T GetItem<T>(IKey key) where T : IKeyable;
|
||||||
List<T> GetAll<T>();
|
|
||||||
void Clear();
|
void Clear();
|
||||||
}
|
}
|
@ -16,8 +16,6 @@ public class FileDataStorage : IDataStorage
|
|||||||
public T GetItem<T>(IKey key) where T : IKeyable =>
|
public T GetItem<T>(IKey key) where T : IKeyable =>
|
||||||
StoreHandlerFactory.GetInstance(key.GetKeyType()).Retrieve<T>(key);
|
StoreHandlerFactory.GetInstance(key.GetKeyType()).Retrieve<T>(key);
|
||||||
|
|
||||||
public List<T> GetAll<T>() => throw new NotImplementedException();
|
|
||||||
|
|
||||||
public void Clear()
|
public void Clear()
|
||||||
{
|
{
|
||||||
// leaving empty so this the File version can still be used it needed
|
// leaving empty so this the File version can still be used it needed
|
||||||
|
@ -29,8 +29,6 @@ public abstract class AbstractStoreHandler : IStoreHandler
|
|||||||
return System.IO.File.Exists(locationWithFile);
|
return System.IO.File.Exists(locationWithFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract List<T> RetrieveAll<T>() where T : IKeyable;
|
|
||||||
|
|
||||||
protected abstract string GetLocation(IKey key);
|
protected abstract string GetLocation(IKey key);
|
||||||
|
|
||||||
protected virtual string GetBaseLocation()
|
protected virtual string GetBaseLocation()
|
||||||
|
@ -2,8 +2,6 @@ namespace LootDumpProcessor.Storage.Implementations.File.Handlers;
|
|||||||
|
|
||||||
public class FlatStoreHandler : AbstractStoreHandler
|
public class FlatStoreHandler : AbstractStoreHandler
|
||||||
{
|
{
|
||||||
public override List<T> RetrieveAll<T>() => throw new NotImplementedException();
|
|
||||||
|
|
||||||
protected override string GetLocation(IKey key)
|
protected override string GetLocation(IKey key)
|
||||||
{
|
{
|
||||||
var baseLocation = GetBaseLocation();
|
var baseLocation = GetBaseLocation();
|
||||||
|
@ -2,8 +2,6 @@ namespace LootDumpProcessor.Storage.Implementations.File.Handlers;
|
|||||||
|
|
||||||
public class SubdivisionedStoreHandler : AbstractStoreHandler
|
public class SubdivisionedStoreHandler : AbstractStoreHandler
|
||||||
{
|
{
|
||||||
public override List<T> RetrieveAll<T>() => throw new NotImplementedException();
|
|
||||||
|
|
||||||
protected override string GetLocation(IKey key)
|
protected override string GetLocation(IKey key)
|
||||||
{
|
{
|
||||||
var location = $"{GetBaseLocation()}/{string.Join("/", key.GetLookupIndex().SkipLast(1))}";
|
var location = $"{GetBaseLocation()}/{string.Join("/", key.GetLookupIndex().SkipLast(1))}";
|
||||||
|
@ -35,8 +35,6 @@ public class MemoryDataStorage : IDataStorage
|
|||||||
return default;
|
return default;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<T> GetAll<T>() => throw new NotImplementedException();
|
|
||||||
|
|
||||||
private string GetLookupKey(IKey key) => string.Join("-", key.GetLookupIndex());
|
private string GetLookupKey(IKey key) => string.Join("-", key.GetLookupIndex());
|
||||||
|
|
||||||
public void Clear()
|
public void Clear()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user