minor changes
change to prototype OOP
add jsdoc support