updated Javadoc, code cleanup, etc.