Housekeeping + documentation

general housekeeping across every file
added javadoc for everything