123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325 |
- [/ Generated by doxygen_xml2qbk 1.1.1, don't change, will be overwritten automatically]
- [/ Generated from xml/group__predicates.xml]
- [section:group__predicates Predicates (boost::geometry::index::)]
- [heading Functions]
- [table
- [[Function][Description]]
- [[[link group__predicates_1gac52a6557110425d4ece53fbd6f9ff866 `contains(Geometry const &)`]][Generate [^[link group__predicates_1gac52a6557110425d4ece53fbd6f9ff866 contains()]] predicate. ]]
- [[[link group__predicates_1ga02dbb7cca47de0b921ef96af464d9590 `covered_by(Geometry const &)`]][Generate [^[link group__predicates_1ga02dbb7cca47de0b921ef96af464d9590 covered_by()]] predicate. ]]
- [[[link group__predicates_1ga0e92e4a20dd19185584fe85847439108 `covers(Geometry const &)`]][Generate [^[link group__predicates_1ga0e92e4a20dd19185584fe85847439108 covers()]] predicate. ]]
- [[[link group__predicates_1ga0aa114ab16f40c8caeb3338adba5d6da `disjoint(Geometry const &)`]][Generate [^[link group__predicates_1ga0aa114ab16f40c8caeb3338adba5d6da disjoint()]] predicate. ]]
- [[[link group__predicates_1ga78cb2ef221b951867c591ffb51b7d8c5 `intersects(Geometry const &)`]][Generate [^[link group__predicates_1ga78cb2ef221b951867c591ffb51b7d8c5 intersects()]] predicate. ]]
- [[[link group__predicates_1ga4a6d33e6f61ad5bff3bdee50a972d54b `overlaps(Geometry const &)`]][Generate [^[link group__predicates_1ga4a6d33e6f61ad5bff3bdee50a972d54b overlaps()]] predicate. ]]
- [[[link group__predicates_1gaabce901b82af2aab10ebbd0dda12f4d5 `within(Geometry const &)`]][Generate [^[link group__predicates_1gaabce901b82af2aab10ebbd0dda12f4d5 within()]] predicate. ]]
- [[[link group__predicates_1ga3213772dd3e54ad03340c2ca66b4f58c `satisfies(UnaryPredicate const &)`]][Generate [link group__predicates_1ga3213772dd3e54ad03340c2ca66b4f58c satisfies()] predicate. ]]
- [[[link group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e `nearest(Geometry const &, unsigned)`]][Generate [link group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e nearest()] predicate. ]]
- ]
- [#group__predicates_1gac52a6557110425d4ece53fbd6f9ff866]
- [section contains(Geometry const &)]
- '''<indexterm><primary>contains</primary></indexterm>'''
- Generate [^[link group__predicates_1gac52a6557110425d4ece53fbd6f9ff866 contains()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that contain passed Geometry. Value is returned by the query if [^`bg::within(Geometry, Indexable)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `contains``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::contains(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga02dbb7cca47de0b921ef96af464d9590]
- [section covered_by(Geometry const &)]
- '''<indexterm><primary>covered_by</primary></indexterm>'''
- Generate [^[link group__predicates_1ga02dbb7cca47de0b921ef96af464d9590 covered_by()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that are covered by passed Geometry. Value is returned by the query if [^`bg::covered_by(Indexable, Geometry)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `covered_by``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::covered_by(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga0e92e4a20dd19185584fe85847439108]
- [section covers(Geometry const &)]
- '''<indexterm><primary>covers</primary></indexterm>'''
- Generate [^[link group__predicates_1ga0e92e4a20dd19185584fe85847439108 covers()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that cover passed Geometry. Value is returned by the query if [^`bg::covered_by(Geometry, Indexable)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `covers``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::covers(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga0aa114ab16f40c8caeb3338adba5d6da]
- [section disjoint(Geometry const &)]
- '''<indexterm><primary>disjoint</primary></indexterm>'''
- Generate [^[link group__predicates_1ga0aa114ab16f40c8caeb3338adba5d6da disjoint()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that are disjoint with passed Geometry. Value is returned by the query if [^`bg::disjoint(Indexable, Geometry)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `disjoint``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::disjoint(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga78cb2ef221b951867c591ffb51b7d8c5]
- [section intersects(Geometry const &)]
- '''<indexterm><primary>intersects</primary></indexterm>'''
- Generate [^[link group__predicates_1ga78cb2ef221b951867c591ffb51b7d8c5 intersects()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that intersect passed Geometry. Value is returned by the query if [^`bg::intersects(Indexable, Geometry)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `intersects``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::intersects(box), std::back_inserter(result));
- bgi::query(spatial_index, bgi::intersects(ring), std::back_inserter(result));
- bgi::query(spatial_index, bgi::intersects(polygon), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga4a6d33e6f61ad5bff3bdee50a972d54b]
- [section overlaps(Geometry const &)]
- '''<indexterm><primary>overlaps</primary></indexterm>'''
- Generate [^[link group__predicates_1ga4a6d33e6f61ad5bff3bdee50a972d54b overlaps()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that overlap passed Geometry. Value is returned by the query if [^`bg::overlaps(Indexable, Geometry)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `overlaps``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::overlaps(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1gaabce901b82af2aab10ebbd0dda12f4d5]
- [section within(Geometry const &)]
- '''<indexterm><primary>within</primary></indexterm>'''
- Generate [^[link group__predicates_1gaabce901b82af2aab10ebbd0dda12f4d5 within()]] predicate.
- [heading Description]
- Generate a predicate defining Value and Geometry relationship. With this predicate query returns indexed Values that are within passed Geometry. Value is returned by the query if [^`bg::within(Indexable, Geometry)`] returns [^`true`].[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `within``(``Geometry const &` `g``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`Geometry`][The Geometry type.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `g` ][The Geometry object. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::within(box), std::back_inserter(result));
- ``
- [endsect]
- [#group__predicates_1ga3213772dd3e54ad03340c2ca66b4f58c]
- [section satisfies(UnaryPredicate const &)]
- '''<indexterm><primary>satisfies</primary></indexterm>'''
- Generate [link group__predicates_1ga3213772dd3e54ad03340c2ca66b4f58c satisfies()] predicate.
- [heading Description]
- A wrapper around user-defined UnaryPredicate checking if Value should be returned by spatial query.[heading Synopsis]
- [pre
- `template<``typename UnaryPredicate``>`
- /unspecified/ `satisfies``(``UnaryPredicate const &` `pred``)`
- ]
- [heading Template parameter(s)]
- [table
- [[Parameter] [Description]]
- [[`UnaryPredicate`][A type of unary predicate function or function object.]]
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`UnaryPredicate const &`][ `pred` ][The unary predicate function or function object. ]]
- ]
- [heading Example]
- ``
- bool is_red(Value const& v) { return v.is_red(); }
- struct is_red_o {
- template <typename Value> bool operator()(Value const& v) { return v.is_red(); }
- }
- // ...
- rt.query(index::intersects(box) && index::satisfies(is_red),
- std::back_inserter(result));
- rt.query(index::intersects(box) && index::satisfies(is_red_o()),
- std::back_inserter(result));
- #ifndef BOOST_NO_CXX11_LAMBDAS
- rt.query(index::intersects(box) && index::satisfies([](Value const& v) { return v.is_red(); }),
- std::back_inserter(result));
- #endif
- ``
- [endsect]
- [#group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e]
- [section nearest(Geometry const &, unsigned)]
- '''<indexterm><primary>nearest</primary></indexterm>'''
- Generate [link group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e nearest()] predicate.
- [heading Description]
- When nearest predicate is passed to the query, k-nearest neighbour search will be performed. [^[link group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e nearest()]] predicate takes a [^`Geometry`] from which distances to [^`Values`] are calculated and the maximum number of [^`Values`] that should be returned. Internally boost::geometry::comparable_distance() is used to perform the calculation.[heading Synopsis]
- [pre
- `template<``typename Geometry``>`
- /unspecified/ `nearest``(``Geometry const &` `geometry``,` `unsigned` `k``)`
- ]
- [heading Parameter(s)]
- [table
- [[Type][Name][Description]]
- [[`Geometry const &`][ `geometry` ][The geometry from which distance is calculated. ]]
- [[`unsigned`][ `k` ][The maximum number of values to return. ]]
- ]
- [heading Example]
- ``
- bgi::query(spatial_index, bgi::nearest(pt, 5), std::back_inserter(result));
- bgi::query(spatial_index, bgi::nearest(pt, 5) && bgi::intersects(box), std::back_inserter(result));
- bgi::query(spatial_index, bgi::nearest(box, 5), std::back_inserter(result));
- ``
- [warning Only one [^[link group__predicates_1ga8772d9d3e5b12b3292f7d94d47310e3e nearest()]] predicate may be used in a query.]
- [endsect]
- [endsect]
|