def METHOD_NAME(self, templatePath):
    """
    Set the path to a template file to render instead of the default template.
    The default template remains available so that custom templates can
    inherit from it. To do so, save the default template filename from
    the templateFilename attribute before calling this function, pass
    it as a variable to the custom template using updateHtmlVars(), and
    reference that variable in an <%inherit> directive like:
        <%inherit file="${context.get('defaultTemplateFilename')}"/>
    """
    templateDir, templateFilename = os.path.split(templatePath)
    self._templateDirs.append(templateDir)
    self.templateFilename = templateFilename
    # Reset TemplateLookup instance so that it will be instantiated lazily,
    # with the latest template directories, on the next GET request
    self._templateLookup = None