clean up and javadoc