def __init__(self, parent, design, view, row_processor=None,
                 include_docs=False, query=None, streaming=True, **params):

        self._parent = parent
        self.design = design
        self.view = view
        self._errors = []
        self.rows_returned = 0
        self._indexed_rows = 0

        # Sentinel used to ensure confusing metadata properties don't get
        # returned unless metadata is actually parsed (or query is complete)
        self.__meta_received = False

        if query and params:
            raise ArgumentError.pyexc(
                "Extra parameters are mutually exclusive with the "
                "'query' argument. Use query.update() to add extra arguments")

        if query:
            if isinstance(query, basestring):
                self._query = ViewQuery.from_string(query)
            else:
                self._query = deepcopy(query)
        else:
            self._query = QueryBase.from_any(params)

        self._flags = 0
        if include_docs:
            self._flags |= C.LCB_CMDVIEWQUERY_F_INCLUDE_DOCS
        if isinstance(self._query, SpatialQuery):
            self._flags |= C.LCB_CMDVIEWQUERY_F_SPATIAL

        if include_docs and self._query.reduce:
            raise ArgumentError.pyexc(
                "include_docs is only applicable for map-only views, but "
                "'reduce', 'group', or 'group_level' was specified; or "
                "this is a spatial query",
                self._query)

        # The original 'limit' parameter, passed to the query.
        self._do_iter = True
        self._mres = None

        if not row_processor:
            if self._spatial:
                row_processor = SpatialRowProcessor()
            else:
                row_processor = RowProcessor()
        self.row_processor = row_processor
Add a job to the job queue
dataset/ETHPy150Open couchbase/couchbase-python-client/couchbase/views/iterator.py/View.__init__--crossover with--dataset/ETHPy150Open BD2KGenomics/toil/src/toil/test/provisioners/clusterScalerTest.py/MockBatchSystemAndProvisioner.Delegate.addJob