Package org.apache.zookeeper.graph
Class LogSkipList
- java.lang.Object
-
- org.apache.zookeeper.graph.LogSkipList
-
public class LogSkipList extends java.lang.ObjectGeneric skip list for holding a rough index of a log file. When the log file is loaded, this index is built by adding a mark every n entries. Then when a specific time position is requested from the file, a point at most n-1 entries before the time position can be jumped to.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classLogSkipList.Mark
-
Constructor Summary
Constructors Constructor Description LogSkipList()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddMark(long time, long bytes, long skipped)LogSkipList.MarkfindMarkBefore(long time)Find the last mark in the skip list before time.
-
-
-
Method Detail
-
addMark
public void addMark(long time, long bytes, long skipped)
-
findMarkBefore
public LogSkipList.Mark findMarkBefore(long time) throws java.util.NoSuchElementException
Find the last mark in the skip list before time.- Throws:
java.util.NoSuchElementException
-
-