Use hash parameters in onetemplate type

/!\ This PR breaks the API by changing the `onetemplate` type using hashs (in accordance with @tuxmea ) to make it more flexible. Comments welcome.