added missing javadoc comments and minor changes