def __init__(self, app=None, renderers=('json', 'jinja2',), default_renderer='html'):
        #: The renderers keyed by MIME type.
        self.mime_type_renderers = {}
        #: The renderers keyed by output format name (such as html).
        self.named_renderers = {}

        #: Hooks for overriding a class' normalizer, even if they explicitly define one.
        #:
        #: All items should be lists of callables. All values default to an empty list.
        self.normalizer_overrides = defaultdict(lambda: [])
        #: Hooks for providing a class with a fallback normalizer, which is called only if it doesn't define one. All items should be callables.
        self.normalizers = {
            basestring: normalizers.normalize_basestring,
            list: normalizers.normalize_iterable,
            tuple: normalizers.normalize_iterable,
            GeneratorType: normalizers.normalize_iterable,
            dict: normalizers.normalize_dict,
            int: normalizers.normalize_int,
            long: normalizers.normalize_int,
            float: normalizers.normalize_float,
            bool: normalizers.normalize_bool,
            NoneType: normalizers.normalize_none,
            datetime.datetime: normalizers.normalize_basestring,
            datetime.date: normalizers.normalize_basestring,
            datetime.time: normalizers.normalize_basestring,
        }

        #: The current app, only set from the constructor, not if using :meth:`init_app`.
        self.app = app or None

        for renderer in renderers:
            if isinstance(renderer, basestring):
                renderer = getattr(_renderers, '%s_renderer' % renderer)

            self.register_renderer(renderer)

        if isinstance(default_renderer, basestring):
            if default_renderer in self.named_renderers:
                default_renderer = self.named_renderers[default_renderer]
            else:
                self.logger.warning(u"Attempted to set the unrenderable format '%s' as the default format, disabling", default_renderer)
                default_renderer = None
        self.default_renderer = default_renderer

        if app:
            self.init_app(app)
dataset/ETHPy150Open teozkr/Flask-Pushrod/flask_pushrod/resolver.py/Pushrod.__init__/original