Fixed some stuff, updated javadoc comments