[+][*] added name property. Also slightly refactored the code. fixes #2