qbegin(rtree<...> const &, Predicates const &)

| Home | Libraries | People | FAQ | More

##### qbegin(rtree<...> const &, Predicates const &)

Returns the query iterator pointing at the begin of the query range.

###### Description

This method returns the iterator which may be used to perform iterative queries. For the information about the predicates which may be passed to this method see query().

###### Synopsis

    template<typename Value,
             typename Parameters,
             typename IndexableGetter,
             typename EqualTo,
             typename Allocator,
             typename Predicates>
    rtree< Value, Parameters, IndexableGetter, EqualTo, Allocator >::const_query_iterator qbegin(rtree< Value, Parameters, IndexableGetter, EqualTo, Allocator > const & tree, Predicates const & predicates)

###### Parameter(s)

Type | Name | Description
--- | --- | ---
`rtree< Value, Parameters, IndexableGetter, EqualTo, Allocator > const &` | `tree` | The rtree.
`Predicates const &` | `predicates` | Predicates.

###### Returns

The iterator pointing at the begin of the query range.

###### Example

    std::for_each(bgi::qbegin(tree, bgi::nearest(pt, 3)), bgi::qend(tree), do_something());

###### Iterator category

ForwardIterator

###### Throws

If predicates copy throws. If allocation throws.

| Warning
The modification of the rtree may invalidate the iterators.