]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/boost/geometry/algorithms/dispatch/disjoint.hpp
update sources to v12.2.3
[ceph.git] / ceph / src / boost / boost / geometry / algorithms / dispatch / disjoint.hpp
1 // Boost.Geometry (aka GGL, Generic Geometry Library)
2
3 // Copyright (c) 2007-2014 Barend Gehrels, Amsterdam, the Netherlands.
4 // Copyright (c) 2008-2014 Bruno Lalande, Paris, France.
5 // Copyright (c) 2009-2014 Mateusz Loskot, London, UK.
6 // Copyright (c) 2013-2014 Adam Wulkiewicz, Lodz, Poland.
7
8 // This file was modified by Oracle on 2013-2017.
9 // Modifications copyright (c) 2013-2017, Oracle and/or its affiliates.
10
11 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
12 // Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
13
14 // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
15 // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
16
17 // Use, modification and distribution is subject to the Boost Software License,
18 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
19 // http://www.boost.org/LICENSE_1_0.txt)
20
21 #ifndef BOOST_GEOMETRY_ALGORITHMS_DISPATCH_DISJOINT_HPP
22 #define BOOST_GEOMETRY_ALGORITHMS_DISPATCH_DISJOINT_HPP
23
24 #include <cstddef>
25
26 #include <boost/geometry/core/tag.hpp>
27 #include <boost/geometry/core/tag_cast.hpp>
28 #include <boost/geometry/core/tags.hpp>
29 #include <boost/geometry/core/reverse_dispatch.hpp>
30
31 #include <boost/geometry/algorithms/not_implemented.hpp>
32
33
34 namespace boost { namespace geometry
35 {
36
37
38 #ifndef DOXYGEN_NO_DISPATCH
39 namespace dispatch
40 {
41
42
43 template
44 <
45 typename Geometry1, typename Geometry2,
46 std::size_t DimensionCount = dimension<Geometry1>::type::value,
47 typename Tag1 = typename tag_cast
48 <
49 typename tag<Geometry1>::type,
50 segment_tag, box_tag, linear_tag, areal_tag
51 >::type,
52 typename Tag2 = typename tag_cast
53 <
54 typename tag<Geometry2>::type,
55 segment_tag, box_tag, linear_tag, areal_tag
56 >::type,
57 bool Reverse = reverse_dispatch<Geometry1, Geometry2>::type::value
58 >
59 struct disjoint
60 : not_implemented<Geometry1, Geometry2>
61 {};
62
63
64 // If reversal is needed, perform it
65 template
66 <
67 typename Geometry1, typename Geometry2,
68 std::size_t DimensionCount,
69 typename Tag1, typename Tag2
70 >
71 struct disjoint<Geometry1, Geometry2, DimensionCount, Tag1, Tag2, true>
72 {
73 template <typename Strategy>
74 static inline bool apply(Geometry1 const& g1, Geometry2 const& g2, Strategy const& strategy)
75 {
76 return disjoint
77 <
78 Geometry2, Geometry1,
79 DimensionCount,
80 Tag2, Tag1
81 >::apply(g2, g1, strategy);
82 }
83 };
84
85
86 } // namespace dispatch
87 #endif // DOXYGEN_NO_DISPATCH
88
89
90 }} // namespace boost::geometry
91
92
93 #endif // BOOST_GEOMETRY_ALGORITHMS_DISPATCH_DISJOINT_HPP