def get_form(self, form_class):
        """Returns an instance of the form to be used in this view."""
        if not hasattr(self, '_form'):
            kwargs = self.get_form_kwargs()
            self._form = form_class(**kwargs)
        return self._form
Returns an instance of the form to be used in this view.