@classmethod
def render_regions(cls, view, **kwargs):
    """
        This is mostly helpful when using ``{% region %}`` template tags. It
        returns all regions when rendering the detail page of the passed
        view. Those regions still have to be filtered using ``changed_regions``
        if you do not want to exchange all snippets.

        When editing data which is used to render a detail page of the same
        or of a different, related model instance, rendering the detail page
        and extracting (potentially) changed parts is necessary for
        live-updating the affected HTML snippets in the frontend.

        This class method achieves exactly that.

        Usage examples::

            # When editing the same model as is on display
            regions = DetailView.render_regions(self)

            # When using towel.resources.inlines
            regions = DetailView.render_regions(self,
                model=self.get_parent_class(),
                object=self.parent,
                )
        """
    self = cls()
    self.request = view.request
    self.model = view.model
    self.object = view.object
    for key, value in kwargs.items():
        setattr(self, key, value)
    regions = {}
    context = self.get_context_data(object=self.object, regions=regions)
    self.render_to_response(context).render()
    return regions
