added comments and Javadoc documentation sections