Applied project structure & some refactoring to the 1.0.x branch from master branch( #62 ) for maintainability.

Please review #62 (project structure & some refactoring) ,and merge to 1.0.x branch.
Tests was all OK.