This commit is contained in:
h z
2024-07-11 12:54:28 +01:00
parent 5b46cce212
commit f59c6edc39
7 changed files with 18 additions and 37 deletions

View File

@@ -9,12 +9,12 @@ namespace Nocturnis.DataStructures;
public class DataCache : CacheItem<DataVariable>
{
public new static DataCache Null => new (x => (0, GlobalProvider.DataStructureProvider!.NullDataType));
public new static DataCache Null => new (x => (null, DataTypeConstant.BaseDataTypes.Null));
public DataCache(Func<CacheItem, DataVariable> rec) : base(rec) => throw new Exception("CONSTRUCTION NOT ALLOWED");
public DataCache(Func<CacheItem, (object, DataType)> rec)
{
Value = GlobalProvider.DataStructureProvider!.NewData(0, DataTypeConstant.BaseDataTypes.Null);
Value = new DataVariable();
ProxyCalculator = rec;
}