Added documentation comments and minor refactorings