Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:35:05

0001 // Boost.Geometry
0002 
0003 // Copyright (c) 2022 Oracle and/or its affiliates.
0004 
0005 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
0006 
0007 // Use, modification and distribution is subject to the Boost Software License,
0008 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
0009 // http://www.boost.org/LICENSE_1_0.txt)
0010 
0011 #ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_EQUALS_IMPLEMENTATION_GC_HPP
0012 #define BOOST_GEOMETRY_ALGORITHMS_DETAIL_EQUALS_IMPLEMENTATION_GC_HPP
0013 
0014 
0015 #include <boost/geometry/algorithms/detail/equals/implementation.hpp>
0016 #include <boost/geometry/algorithms/detail/relate/implementation_gc.hpp>
0017 
0018 
0019 namespace boost { namespace geometry
0020 {
0021 
0022 
0023 #ifndef DOXYGEN_NO_DISPATCH
0024 namespace dispatch
0025 {
0026 
0027 
0028 template <typename Geometry1, typename Geometry2, std::size_t DimensionCount>
0029 struct equals
0030     <
0031         Geometry1, Geometry2,
0032         geometry_collection_tag, geometry_collection_tag,
0033         geometry_collection_tag, geometry_collection_tag,
0034         DimensionCount, false
0035     >
0036 {
0037     template <typename Strategy>
0038     static inline bool apply(Geometry1 const& geometry1,
0039                              Geometry2 const& geometry2,
0040                              Strategy const& strategy)
0041     {
0042         return detail::relate::relate_impl
0043             <
0044                 detail::de9im::static_mask_equals_type,
0045                 Geometry1,
0046                 Geometry2
0047             >::apply(geometry1, geometry2, strategy);
0048     }
0049 };
0050 
0051 
0052 template
0053 <
0054     typename Geometry1, typename Geometry2,
0055     typename Tag1, typename CastedTag1,
0056     std::size_t DimensionCount
0057 >
0058 struct equals
0059     <
0060         Geometry1, Geometry2,
0061         Tag1, geometry_collection_tag,
0062         CastedTag1, geometry_collection_tag,
0063         DimensionCount, false
0064     >
0065 {
0066     template <typename Strategy>
0067     static inline bool apply(Geometry1 const& geometry1,
0068                              Geometry2 const& geometry2,
0069                              Strategy const& strategy)
0070     {
0071         using gc1_view_t = detail::geometry_collection_view<Geometry1>;
0072         return equals
0073             <
0074                 gc1_view_t, Geometry2
0075             >::apply(gc1_view_t(geometry1), geometry2, strategy);
0076     }
0077 };
0078 
0079 
0080 template
0081 <
0082     typename Geometry1, typename Geometry2,
0083     typename Tag2, typename CastedTag2,
0084     std::size_t DimensionCount
0085 >
0086 struct equals
0087     <
0088         Geometry1, Geometry2,
0089         geometry_collection_tag, Tag2,
0090         geometry_collection_tag, CastedTag2,
0091         DimensionCount, false
0092     >
0093 {
0094     template <typename Strategy>
0095     static inline bool apply(Geometry1 const& geometry1,
0096                              Geometry2 const& geometry2,
0097                              Strategy const& strategy)
0098     {
0099         using gc2_view_t = detail::geometry_collection_view<Geometry2>;
0100         return equals
0101             <
0102                 Geometry1, gc2_view_t
0103             >::apply(geometry1, gc2_view_t(geometry2), strategy);
0104     }
0105 };
0106 
0107 
0108 } // namespace dispatch
0109 #endif // DOXYGEN_NO_DISPATCH
0110 
0111 
0112 }} // namespace boost::geometry
0113 
0114 #endif // BOOST_GEOMETRY_ALGORITHMS_DETAIL_EQUALS_IMPLEMENTATION_GC_HPP