public IterateBackwardStartsWithClosestToPrefix ( byte initKey, bool useCache ) : IEnumerable |
||
initKey | byte | |
useCache | bool | |
return | IEnumerable |
/// <summary> /// /// </summary> /// <param name="startKey"></param> /// <param name="readRootNode"></param> /// <returns></returns> public IEnumerable<LTrieRow> IterateBackwardStartsWithClosestToPrefix(byte[] startKey, ITrieRootNode readRootNode) { this.CheckTableIsOperable(); if (readRootNode == null) { //Flashing changes on the disk before commit. In case if the same thread uses the same root node this.SaveGenerationMap(); Backward bw = new Backward(rn); return bw.IterateBackwardStartsWithClosestToPrefix(startKey, false); } else { Backward bw = new Backward((LTrieRootNode)readRootNode); return bw.IterateBackwardStartsWithClosestToPrefix(startKey, true); } }
/// <summary> /// /// </summary> /// <param name="startKey"></param> /// <returns></returns> public IEnumerable<LTrieRow> IterateBackwardStartsWithClosestToPrefix(byte[] startKey) { this.CheckTableIsOperable(); LTrieRootNode readRootNode = new LTrieRootNode(this); Backward bw = new Backward(readRootNode); return bw.IterateBackwardStartsWithClosestToPrefix(startKey, true); }