use stylecop to add documentation and refactor