point_geometry.hpp 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. // Boost.Geometry (aka GGL, Generic Geometry Library)
  2. // Copyright (c) 2007-2015 Barend Gehrels, Amsterdam, the Netherlands.
  3. // Copyright (c) 2008-2015 Bruno Lalande, Paris, France.
  4. // Copyright (c) 2009-2015 Mateusz Loskot, London, UK.
  5. // Copyright (c) 2013-2015 Adam Wulkiewicz, Lodz, Poland.
  6. // This file was modified by Oracle on 2013-2022.
  7. // Modifications copyright (c) 2013-2022, Oracle and/or its affiliates.
  8. // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
  9. // Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
  10. // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
  11. // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
  12. // Use, modification and distribution is subject to the Boost Software License,
  13. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  14. // http://www.boost.org/LICENSE_1_0.txt)
  15. #ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_DISJOINT_POINT_GEOMETRY_HPP
  16. #define BOOST_GEOMETRY_ALGORITHMS_DETAIL_DISJOINT_POINT_GEOMETRY_HPP
  17. #include <boost/geometry/algorithms/detail/covered_by/implementation.hpp>
  18. #include <boost/geometry/algorithms/detail/disjoint/linear_linear.hpp>
  19. #include <boost/geometry/algorithms/dispatch/disjoint.hpp>
  20. namespace boost { namespace geometry
  21. {
  22. #ifndef DOXYGEN_NO_DETAIL
  23. namespace detail { namespace disjoint
  24. {
  25. struct reverse_covered_by
  26. {
  27. template <typename Geometry1, typename Geometry2, typename Strategy>
  28. static inline bool apply(Geometry1 const& geometry1,
  29. Geometry2 const& geometry2,
  30. Strategy const& strategy)
  31. {
  32. return ! geometry::covered_by(geometry1, geometry2, strategy);
  33. }
  34. };
  35. }} // namespace detail::disjoint
  36. #endif // DOXYGEN_NO_DETAIL
  37. #ifndef DOXYGEN_NO_DISPATCH
  38. namespace dispatch
  39. {
  40. template<typename Point, typename Linear, std::size_t DimensionCount>
  41. struct disjoint<Point, Linear, DimensionCount, point_tag, linear_tag, false>
  42. : detail::disjoint::reverse_covered_by
  43. {};
  44. template <typename Point, typename Areal, std::size_t DimensionCount>
  45. struct disjoint<Point, Areal, DimensionCount, point_tag, areal_tag, false>
  46. : detail::disjoint::reverse_covered_by
  47. {};
  48. template<typename Point, typename Segment, std::size_t DimensionCount>
  49. struct disjoint<Point, Segment, DimensionCount, point_tag, segment_tag, false>
  50. : detail::disjoint::reverse_covered_by
  51. {};
  52. } // namespace dispatch
  53. #endif // DOXYGEN_NO_DISPATCH
  54. }} // namespace boost::geometry
  55. #endif // BOOST_GEOMETRY_ALGORITHMS_DETAIL_DISJOINT_POINT_GEOMETRY_HPP