Re #1227 Refactoring and Javadoc