class LuceneIndexEngine {

    public void createIndex(final String docsPath) {
        final File docDir = fileFactory.createFile(docsPath);
        if (!docDir.exists() || !docDir.canRead()) {
            logger.error("Document directory '" + docDir.getAbsolutePath() + "' does not exist or is not readable, please check the path");
        } else {
            indexFolder(docDir);
        }
    }

}