net.sf.kernow.util
Class FileListBuilder

java.lang.Object
  extended by net.sf.kernow.util.FileListBuilder

public class FileListBuilder
extends java.lang.Object

A class that creates a list of files for a given directory by (optionally) recursing the directory. The files added to the list must have a suffix that matches one of the suffixes supplied using the allowedInputSuffix String.


Constructor Summary
FileListBuilder()
           
 
Method Summary
static java.util.ArrayList<java.io.File> buildFileList(java.io.File dir, java.lang.String allowedInputSuffixes, boolean recurseSubdirectories)
          Returns an ArrayList of Files contained in the supplied directory by comparing the suffix of each file with the list of comma separated suffixes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileListBuilder

public FileListBuilder()
Method Detail

buildFileList

public static java.util.ArrayList<java.io.File> buildFileList(java.io.File dir,
                                                              java.lang.String allowedInputSuffixes,
                                                              boolean recurseSubdirectories)
Returns an ArrayList of Files contained in the supplied directory by comparing the suffix of each file with the list of comma separated suffixes

Parameters:
dir - The directory to build the file list for
allowedInputSuffixes - A comma separated list of allowed input suffixes
recurseSubdirectories - true to recusively process subdirectories
Returns:
The list of the files with matching suffixes for the directory