Refactoring

going to slowly create java docs for the code to make it easier to
remember what everything does.