def render(): ex = get_exporter(key) with io.StringIO() as buf: self._context.globals['options'][ 'controller'].apply_export_filter(self._target, ex, filename=buf) res = TypedUnicode(buf.getvalue()) res.contenttype = ex.mimetype return res
def keys(self): """Returns the ids of valid exporters """ return list(get_exporter().keys())
def __contains__(self, key): v = get_exporter(key) return v is not None