Small refactoring
Added more doc and small refactoring.