Class FilesScanner

    • Constructor Summary

      Constructors 
      Constructor Description
      FilesScanner​(java.lang.String[] fileNames, boolean recursive)
      Scan from a set of packages.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()
      Default implementation of #close() which does nothing.
      boolean hasNext()  
      private void init()  
      java.lang.String next()  
      java.io.InputStream open()
      Open current resource.
      private void processFile​(java.io.File f)  
      void reset()
      Reset the ResourceFinder instance.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Iterator

        forEachRemaining
    • Field Detail

      • files

        private final java.io.File[] files
      • recursive

        private final boolean recursive
    • Constructor Detail

      • FilesScanner

        public FilesScanner​(java.lang.String[] fileNames,
                            boolean recursive)
        Scan from a set of packages.
        Parameters:
        fileNames - an array of package names.
        recursive - flag indicating whether sub-directories of any directories in the list of files should be included in the scanning (true) or not (false).
    • Method Detail

      • processFile

        private void processFile​(java.io.File f)
      • hasNext

        public boolean hasNext()
      • next

        public java.lang.String next()
      • open

        public java.io.InputStream open()
        Description copied from interface: ResourceFinder
        Open current resource.
        Returns:
        input stream from which current resource can be loaded.
      • reset

        public void reset()
        Description copied from interface: ResourceFinder
        Reset the ResourceFinder instance.

        Upon calling this method the implementing class MUST reset its internal state to the initial state.

      • init

        private void init()