added some javadoc and removed unused imports