Improved the JavaDoc and fixed some checkstyle issues