Little bit of cleanup. Added some javadoc.