Java doc, refactoring