doc/style updates

updated javadoc and code formatting