Removed unused imports. Added some Javadoc.