add some Javadoc
add Javadoc and fix some code style