code: def has_template(self, uri):
          
          try:
              self.get_template(uri)
              return True
          except exceptions.TemplateLookupException:
              return False
docs: Return ``True`` if this :class:`.TemplateLookup` is
          capable of returning a :class:`.Template` object for the
          given ``uri``.
  
          :param uri: String URI of the template to be resolved.