fix use of deprecated method
fix javadoc