add index.js to use access point of this library

and add template of instance/class method and public/private methods