/// <summary> /// Opens an existing resource index from the specified page store /// </summary> /// <param name="pageStore"></param> /// <param name="resourceTable">The table used to store long resource strings</param> /// <param name="rootNodeId">The ID of the page that contains the root node of the resource index</param> public ResourceIndex(IPageStore pageStore, IResourceTable resourceTable, ulong rootNodeId) : base(pageStore, rootNodeId) { //_resourceCache = new ConcurrentResourceCache(); //_resourceIdCache = new ConcurrentResourceIdCache(); _resourceCache = new LruResourceCache(); _resourceIdCache = new LruResourceIdCache(); _resourceStore = new ResourceStore(resourceTable); #if DEBUG_BTREE Configuration.DebugId = "ResIx"; Logging.LogDebug("Opened new {0} BTree with root page {1}", Configuration.DebugId, rootNodeId); #endif }
/// <summary> /// Creates a new empty resource index in the specified page store /// </summary> /// <param name="txnId"></param> /// <param name="pageStore"></param> /// <param name="resourceTable"></param> public ResourceIndex(ulong txnId, IPageStore pageStore, IResourceTable resourceTable) : base(txnId, pageStore) { //_resourceCache = new ConcurrentResourceCache(); //_resourceIdCache = new ConcurrentResourceIdCache(); _resourceCache = new LruResourceCache(); _resourceIdCache = new LruResourceIdCache(); _resourceStore = new ResourceStore(resourceTable); #if DEBUG_BTREE Configuration.DebugId = "ResIx"; Logging.LogDebug("Created new {0} BTree with root page {1}", Configuration.DebugId, RootId); #endif }
/// <summary> /// Opens an existing resource index from the specified page store /// </summary> /// <param name="pageStore"></param> /// <param name="resourceTable">The table used to store long resource strings</param> /// <param name="rootNodeId">The ID of the page that contains the root node of the resource index</param> public ResourceIndex(IPageStore pageStore, IResourceTable resourceTable, ulong rootNodeId) : base(pageStore, rootNodeId) { //_resourceCache = new ConcurrentResourceCache(); //_resourceIdCache = new ConcurrentResourceIdCache(); _resourceCache= new LruResourceCache(); _resourceIdCache = new LruResourceIdCache(); _resourceStore = new ResourceStore(resourceTable); #if DEBUG_BTREE Configuration.DebugId = "ResIx"; Logging.LogDebug("Opened new {0} BTree with root page {1}", Configuration.DebugId, rootNodeId); #endif }
/// <summary> /// Opens an existing resource index from the specified page store /// </summary> /// <param name="pageStore"></param> /// <param name="resourceTable">The table used to store long resource strings</param> /// <param name="rootNodeId">The ID of the page that contains the root node of the resource index</param> public ResourceIndex(IPageStore pageStore, IResourceTable resourceTable, ulong rootNodeId) : base(pageStore, rootNodeId) { _resourceCache = new ConcurrentResourceCache(); _resourceIdCache = new ConcurrentResourceIdCache(); _resourceStore = new ResourceStore(resourceTable); }