  class MultipleObjectBaseView(MultipleObjectMixin, BaseView):
      """
      Base class for generic views onto a queryset.
      """
      pass
  
  
  class SingleObjectBaseView(SingleObjectMixin, BaseView):
      """
      Base class for generic views onto a model instance.
 
</s> remove         ret = serializer_class(instance=page, context=context)
        ret.fields['results'] = self.get_serializer(kwargs={'source': 'object_list'})
        return ret
 </s> add         return serializer_class(data, instance=instance, context=context) </s> remove     pagination_serializer_class = api_settings.PAGINATION_SERIALIZER
    paginate_by = api_settings.PAGINATE_BY
 </s> add  </s> remove class TestPaginatedView(TestCase):
 </s> add class IntegrationTestPagination(TestCase):
    """
    Integration tests for paginated list views.
    """
 </s> remove     def get_serializer(self, data=None, files=None, instance=None, kwargs=None):
        # TODO: add support for files
        # TODO: add support for seperate serializer/deserializer
 </s> add     def get_serializer_class(self):
        """
        Return the class to use for the serializer.
        Use `self.serializer_class`, falling back to constructing a
        model serializer class from `self.model_serializer_class`
        """
    pagination_serializer_class = api_settings.PAGINATION_SERIALIZER
    paginate_by = api_settings.PAGINATE_BY

    def get_pagination_serializer_class(self):
        """
        Return the class to use for the pagination serializer.
        """
        class SerializerClass(self.pagination_serializer_class):
            class Meta:
                object_serializer_class = self.get_serializer_class()

        return SerializerClass

    def get_pagination_serializer(self, page=None):
        pagination_serializer_class = self.get_pagination_serializer_class()
        context = self.get_serializer_context()
        return pagination_serializer_class(instance=page, context=context)
  class MultipleObjectBaseView(MultipleObjectMixin, BaseView):
      """
      Base class for generic views onto a queryset.
      """
    pagination_serializer_class = api_settings.PAGINATION_SERIALIZER
    paginate_by = api_settings.PAGINATE_BY

    def get_pagination_serializer_class(self):
        """
        Return the class to use for the pagination serializer.
        """
        class SerializerClass(self.pagination_serializer_class):
            class Meta:
                object_serializer_class = self.get_serializer_class()

        return SerializerClass

    def get_pagination_serializer(self, page=None):
        pagination_serializer_class = self.get_pagination_serializer_class()
        context = self.get_serializer_context()
        return pagination_serializer_class(instance=page, context=context)
  
  
  class SingleObjectBaseView(SingleObjectMixin, BaseView):
      """
      Base class for generic views onto a model instance.
keep keep keep keep replace keep keep keep keep keep
 Expand pagination support, add docs 
rest_framework/generics.py