Added / edited javadocs and comments.