}
// make sure path exists and is readable
File file = new File(filePath);
if(!file.exists()) {
throw new FileNotFoundException("Invalid path ["+path+"], "+
"directory doesn't exist.");
} else if(!file.canRead()) {
throw new FilePathException("Invalid path ["+path+"], "+
"cannot read from path.");
}