Wrote some javadocs.