/// <inheritdoc /> public TMajor AddNew(FormKey formKey) { var ret = MajorRecordInstantiator <TMajor> .Activator(formKey, _release); InternalCache.Set(ret); return(ret); }
/// <inheritdoc /> public TMajor AddNew() { var ret = MajorRecordInstantiator <TMajor> .Activator(SourceMod.GetNextFormKey(), _release); InternalCache.Set(ret); return(ret); }
public static void Set <T>(string key, T value, TimeSpan slidingExpiration) { Check.Argument.IsNotNullOrEmpty(key, "key"); Check.Argument.IsNotNegativeOrZero(slidingExpiration, "absoluteExpiration"); InternalCache.Set(key, value, slidingExpiration); }
public static void Set <T>(string key, T value, DateTime absoluteExpiration) { Check.Argument.IsNotNullOrEmpty(key, "key"); Check.Argument.IsNotInPast(absoluteExpiration, "absoluteExpiration"); InternalCache.Set(key, value, absoluteExpiration); }
/// <inheritdoc /> public TMajor AddNew(string editorID) { var ret = MajorRecordInstantiator <TMajor> .Activator(SourceMod.GetNextFormKey(editorID), _release); ret.EditorID = editorID; InternalCache.Set(ret); return(ret); }
/// <inheritdoc /> public void Set(IEnumerable <TMajor> items) => InternalCache.Set(items);
/// <inheritdoc /> public void Set(TMajor item) => InternalCache.Set(item);
/// <inheritdoc /> public void Set(IEnumerable <TMajor> records) => InternalCache.Set(records);
/// <inheritdoc /> public void Set(TMajor record) => InternalCache.Set(record);
public static void Set <T>(string key, T value) { Check.Argument.IsNotNullOrEmpty(key, "key"); InternalCache.Set(key, value); }