org.databene.commons
Class ReaderLineIterator

java.lang.Object
  extended by org.databene.commons.ReaderLineIterator
All Implemented Interfaces:
java.io.Closeable, java.util.Iterator<java.lang.String>, HeavyweightIterator<java.lang.String>

public class ReaderLineIterator
extends java.lang.Object
implements HeavyweightIterator<java.lang.String>

Iterator implementation that returns text lines provided by a reader.

Created: 01.05.2007 08:06:46

Since:
0.1
Author:
Volker Bergmann

Constructor Summary
ReaderLineIterator(java.io.Reader reader)
           
ReaderLineIterator(java.io.Reader reader, boolean skipEmptyLines)
           
 
Method Summary
 void close()
           
 boolean hasNext()
           
 int lineCount()
           
 java.lang.String next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReaderLineIterator

public ReaderLineIterator(java.io.Reader reader)

ReaderLineIterator

public ReaderLineIterator(java.io.Reader reader,
                          boolean skipEmptyLines)
Method Detail

close

public void close()
Specified by:
close in interface java.io.Closeable

lineCount

public int lineCount()

hasNext

public boolean hasNext()
Specified by:
hasNext in interface java.util.Iterator<java.lang.String>

next

public java.lang.String next()
Specified by:
next in interface java.util.Iterator<java.lang.String>

remove

public void remove()
Specified by:
remove in interface java.util.Iterator<java.lang.String>


Copyright © 2010. All Rights Reserved.