Updated scaladoc throughout the codebase