/** * Returns the next element in the iteration. */ @Override public File next() { if (next == null) { throw new NoSuchElementException("FileSequentialCollection exhausted"); } File ret = next; next = primeNextFile(); return ret; }
/** * Returns the next element in the iteration. */ public File next() { if (next == null) { throw new NoSuchElementException("FileSequentialCollection exhausted"); } File ret = next; next = primeNextFile(); return ret; }
public FileSequentialCollectionIterator() { // System.err.println("Coll is " + coll); roots = coll.toArray(); rootsIndex = 0; fileArrayStack = new Stack<Object>(); fileArrayStackIndices = new Stack<Integer>(); if (roots.length > 0) { fileArrayStack.add(roots[rootsIndex]); fileArrayStackIndices.push(Integer.valueOf(0)); } next = primeNextFile(); }
/** * Return an Iterator over files in the collection. * This version lazily works its way down directories. */ @Override public Iterator<File> iterator() { return new FileSequentialCollectionIterator(); }
public FileSequentialCollectionIterator() { // System.err.println("Coll is " + coll); roots = coll.toArray(); rootsIndex = 0; fileArrayStack = new Stack<Object>(); fileArrayStackIndices = new Stack<Integer>(); if (roots.length > 0) { fileArrayStack.add(roots[rootsIndex]); fileArrayStackIndices.push(Integer.valueOf(0)); } next = primeNextFile(); }
/** * Return an Iterator over files in the collection. * This version lazily works its way down directories. */ @Override public Iterator<File> iterator() { return new FileSequentialCollectionIterator(); }
/** * Return an Iterator over files in the collection. * This version lazily works its way down directories. */ @Override public Iterator<File> iterator() { return new FileSequentialCollectionIterator(); }
/** * Returns the next element in the iteration. */ @Override public File next() { if (next == null) { throw new NoSuchElementException("FileSequentialCollection exhausted"); } File ret = next; next = primeNextFile(); return ret; }
public FileSequentialCollectionIterator() { // log.info("Coll is " + coll); roots = coll.toArray(); rootsIndex = 0; fileArrayStack = new Stack<>(); fileArrayStackIndices = new Stack<>(); if (roots.length > 0) { fileArrayStack.add(roots[rootsIndex]); fileArrayStackIndices.push(Integer.valueOf(0)); } next = primeNextFile(); }
/** * Returns the next element in the iteration. */ public File next() { if (next == null) { throw new NoSuchElementException("FileSequentialCollection exhausted"); } File ret = next; next = primeNextFile(); return ret; }
/** * Return an Iterator over files in the collection. * This version lazily works its way down directories. */ @Override public Iterator<File> iterator() { return new FileSequentialCollectionIterator(); }
public FileSequentialCollectionIterator() { // log.info("Coll is " + coll); roots = coll.toArray(); rootsIndex = 0; fileArrayStack = new Stack<>(); fileArrayStackIndices = new Stack<>(); if (roots.length > 0) { fileArrayStack.add(roots[rootsIndex]); fileArrayStackIndices.push(Integer.valueOf(0)); } next = primeNextFile(); }