You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@samoa.apache.org by gd...@apache.org on 2016/04/19 10:35:06 UTC
[07/19] incubator-samoa git commit: SAMOA-58: A tentative solution to
issue described in:
SAMOA-58: A tentative solution to issue described in:
https://issues.apache.org/jira/browse/SAMOA-58
Project: http://git-wip-us.apache.org/repos/asf/incubator-samoa/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-samoa/commit/16046cce
Tree: http://git-wip-us.apache.org/repos/asf/incubator-samoa/tree/16046cce
Diff: http://git-wip-us.apache.org/repos/asf/incubator-samoa/diff/16046cce
Branch: refs/heads/master
Commit: 16046cce5609fc1d505da72901c8fecdf708d844
Parents: ebb3516
Author: edi_bice <ed...@yahoo.com>
Authored: Thu Feb 18 17:06:12 2016 -0500
Committer: Gianmarco De Francisci Morales <gd...@apache.org>
Committed: Tue Apr 19 11:33:42 2016 +0300
----------------------------------------------------------------------
.../main/java/org/apache/samoa/streams/FileStream.java | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-samoa/blob/16046cce/samoa-api/src/main/java/org/apache/samoa/streams/FileStream.java
----------------------------------------------------------------------
diff --git a/samoa-api/src/main/java/org/apache/samoa/streams/FileStream.java b/samoa-api/src/main/java/org/apache/samoa/streams/FileStream.java
index eece541..2998b22 100644
--- a/samoa-api/src/main/java/org/apache/samoa/streams/FileStream.java
+++ b/samoa-api/src/main/java/org/apache/samoa/streams/FileStream.java
@@ -80,7 +80,16 @@ public abstract class FileStream extends AbstractOptionHandler implements Instan
@Override
public boolean hasMoreInstances() {
- return !this.hitEndOfStream;
+ if (this.hitEndOfStream) {
+ if (getNextFileReader()) {
+ this.hitEndOfStream = false;
+ return hasMoreInstances();
+ } else {
+ return false;
+ }
+ } else {
+ return true;
+ }
}
@Override