Class SourceFilesEnumeration

java.lang.Object
com.github.blutorange.maven.plugin.closurecompiler.common.SourceFilesEnumeration
All Implemented Interfaces:
Enumeration<InputStream>

public class SourceFilesEnumeration extends Object implements Enumeration<InputStream>
Used to initialize a SequenceInputStream with a Enumeration<? extends InputStream>. The input streams that are produced by the enumeration will be read, in order, to provide the bytes to be read from the SequenceInputStream.
  • Constructor Details

    • SourceFilesEnumeration

      public SourceFilesEnumeration(org.apache.maven.plugin.logging.Log log, List<File> files, Charset charset, String lineSeparator)
      Enumeration public constructor.
      Parameters:
      log - Maven plugin log
      files - list of files
      charset - Encoding to be used.
      lineSeparator - String used to separate lines.
  • Method Details

    • hasMoreElements

      public boolean hasMoreElements()
      Tests if this enumeration contains more elements.
      Specified by:
      hasMoreElements in interface Enumeration<InputStream>
      Returns:
      true if and only if this enumeration object contains at least one more element to provide; false otherwise.
    • nextElement

      public InputStream nextElement()
      Returns the next element of this enumeration if this enumeration object has at least one more element to provide.
      Specified by:
      nextElement in interface Enumeration<InputStream>
      Returns:
      the next element of this enumeration.
      Throws:
      NoSuchElementException - if no more elements exist.