Class FileBackedDictionary.FileLookaheadIterator

  • All Implemented Interfaces:
    java.util.Iterator
    Direct Known Subclasses:
    FileBackedDictionary.IndexFileLookaheadIterator
    Enclosing class:
    FileBackedDictionary

    private abstract class FileBackedDictionary.FileLookaheadIterator
    extends java.lang.Object
    implements java.util.Iterator
    A lookahead iterator over a dictionary file. Each element in the enumeration is a line in the enumerated file.
    • Field Detail

      • _currentLine

        private java.lang.String _currentLine
      • _currentOffset

        private long _currentOffset
      • _nextOffset

        private long _nextOffset
      • _more

        private boolean _more
      • _pos

        protected POS _pos
    • Constructor Detail

    • Method Detail

      • parseLine

        protected abstract java.lang.Object parseLine​(POS pos,
                                                      long offset,
                                                      java.lang.String line)
      • next

        public final java.lang.Object next()
        Specified by:
        next in interface java.util.Iterator
      • hasNext

        public final boolean hasNext()
        Specified by:
        hasNext in interface java.util.Iterator
      • remove

        public void remove()
        This method can be over-ridden to remove the currently pointed-at object from the data source backing the iterator.
        Specified by:
        remove in interface java.util.Iterator
      • nextLine

        protected final void nextLine()
        Read the next line in the iterated file.