/// <summary> /// This API supports the Entity Framework Core infrastructure and is not intended to be used /// directly from your code. This API may change or be removed in future releases. /// </summary> public LiteDBStore( [NotNull] ILiteDBTableFactory tableFactory, bool useNameMatching, string name) { _tableFactory = tableFactory; LiteDatabase = new LiteDB.LiteDatabase(name); _tableFactory.LiteDatabase = LiteDatabase; _useNameMatching = useNameMatching; _tables = CreateTables(); }
/// <summary> /// This API supports the Entity Framework Core infrastructure and is not intended to be used /// directly from your code. This API may change or be removed in future releases. /// </summary> public LiteDBStoreCache( [NotNull] ILiteDBTableFactory tableFactory, [CanBeNull] ILiteDBSingletonOptions options) { _tableFactory = tableFactory; if (options?.DatabaseRoot != null) { _useNameMatching = true; LazyInitializer.EnsureInitialized( ref options.DatabaseRoot.Instance, () => new ConcurrentDictionary <string, ILiteDBStore>()); _namedStores = (ConcurrentDictionary <string, ILiteDBStore>)options.DatabaseRoot.Instance; } else { _namedStores = new ConcurrentDictionary <string, ILiteDBStore>(); } }
public LiteDBStoreCache([NotNull] ILiteDBTableFactory tableFactory) : this(tableFactory, null) { }
/// <summary> /// This API supports the Entity Framework Core infrastructure and is not intended to be used /// directly from your code. This API may change or be removed in future releases. /// </summary> public LiteDBStore([NotNull] ILiteDBTableFactory tableFactory, string name) : this(tableFactory, useNameMatching : false, name) { }