adds some implementation for TemplateGenerator