Class FileSystemIterator

java.lang.Object
com.helger.collection.commons.CommonsIterableIterator<File>
com.helger.io.file.FileSystemIterator
All Implemented Interfaces:
com.helger.base.iface.IHasSize, com.helger.collection.base.IIterableIterator<File>, com.helger.collection.commons.ICommonsIterable<File>, com.helger.collection.commons.ICommonsIterableIterator<File>, Iterable<File>, Iterator<File>

@NotThreadSafe public final class FileSystemIterator extends com.helger.collection.commons.CommonsIterableIterator<File>
Iterate over the content of a single directory. Iteration is not recursive.
Author:
Philip Helger
  • Constructor Summary

    Constructors
    Constructor
    Description
    FileSystemIterator(@NonNull File aBaseDir)
    Constructor.
    FileSystemIterator(@NonNull File aBaseDir, @NonNull String sDirName)
    Constructor.
    FileSystemIterator(@NonNull String sBaseDir)
    Constructor.
  • Method Summary

    Methods inherited from class com.helger.collection.commons.CommonsIterableIterator

    createEmpty, hasNext, iterator, next, remove, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.helger.collection.commons.ICommonsIterable

    containsAny, containsNone, containsOnly, findAll, findAllInstanceOf, findAllMapped, findAllMapped, findAllMapped, findFirst, findFirst, findFirstIndex, findFirstMapped, findFirstMapped, findLastIndex, forEachBreakable, forEachByIndex, forEachThrowing, getCount, isEmpty, size

    Methods inherited from interface com.helger.collection.commons.ICommonsIterableIterator

    withFilter, withMapper

    Methods inherited from interface com.helger.base.iface.IHasSize

    isNotEmpty

    Methods inherited from interface java.lang.Iterable

    forEach, spliterator

    Methods inherited from interface java.util.Iterator

    forEachRemaining
  • Constructor Details

    • FileSystemIterator

      public FileSystemIterator(@NonNull String sBaseDir)
      Constructor.
      Parameters:
      sBaseDir - The base directory to iterate. May not be null.
    • FileSystemIterator

      public FileSystemIterator(@NonNull File aBaseDir)
      Constructor.
      Parameters:
      aBaseDir - The base directory to iterate. May not be null.
    • FileSystemIterator

      public FileSystemIterator(@NonNull File aBaseDir, @NonNull String sDirName)
      Constructor.
      Parameters:
      aBaseDir - The base directory to iterate. May not be null.
      sDirName - The directory name relative to the passed base directory. May not be null.