Added some documentation
Fix coding style