0
0
mirror of https://github.com/sp-tarkov/loot-dump-processor.git synced 2025-02-13 09:50:44 -05:00
CWX 39ac387aae
Per map process (#1)
* Seperate Tasks into their own methods, Add method to add map name to file name

* Formatting and added a few comments

* Add Clear method to collectors

* Change to local var, so data isnt stored longer than needed

* add Clear method to Storages

* Add changes for Per Map Processing and file i forgot to commit last time

* Update config to have mapNames in it, removed unused yaml file

* update comment

* changed to not throw so Filemode still can be used
2024-12-31 09:12:48 +00:00

33 lines
750 B
C#

namespace LootDumpProcessor.Storage.Implementations.File;
public class FileDataStorage : IDataStorage
{
public void Setup()
{
}
public void Store<T>(T t) where T : IKeyable
{
StoreHandlerFactory.GetInstance(t.GetKey().GetKeyType()).Store(t);
}
public bool Exists(IKey t)
{
return StoreHandlerFactory.GetInstance(t.GetKeyType()).Exists(t);
}
public T GetItem<T>(IKey key) where T : IKeyable
{
return StoreHandlerFactory.GetInstance(key.GetKeyType()).Retrieve<T>(key);
}
public List<T> GetAll<T>()
{
throw new NotImplementedException();
}
public void Clear()
{
// leaving empty so this the File version can still be used it needed
}
}