private static class LogInputFile.LogInputFileIterator extends Object implements Iterator
Iterator returned by
LogInputStream.logs. The next method
occasionally returns null.next()| Modifier and Type | Field and Description |
|---|---|
private LogFile |
baseLogFile |
private Iterator |
fileList |
| Constructor and Description |
|---|
LogInputFileIterator(Collection files,
LogFile baseLogFile)
Create a new
LogInputFileIterator object
for the given list. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasNext() |
Object |
next()
Return the next
File object, or
null. |
void |
remove()
Remove the
File object returned by the iterator
from the list. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingLogInputFileIterator(Collection files, LogFile baseLogFile)
LogInputFileIterator object
for the given list.public Object next()
File object, or
null. You will get null when the
file existed at the time of listing, but no longer exists
when the iterator gets to it. For example, if a process is
consuming all completed logs, the listing might find a log,
but that process may have consumed and removed it by the
time you invoke next, so you will get a
null.Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.