first commit

This commit is contained in:
redtea committed 2024-05-23 23:21:24 +03:00
1 parent a9f02f8595
commit 1f6634add4
83 files changed
+28739

No files matched your search

+26
View File
@@ -0,0 +1,26 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PaymentLogs.Repositories
{
internal abstract class Repo<K, V>
{
protected Dictionary<K, V> _data = new Dictionary<K, V>();
public abstract void Load();
public virtual List<V> All()
{
return _data.Values.ToList();
}
public virtual V Get(K key) { return _data[key]; }
public virtual void Update(K key, V value)
{
_data[key] = value;
}
public abstract void Save();
}
}