// Boost.Geometry // Copyright (c) 2021, Oracle and/or its affiliates. // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle // Licensed under the Boost Software License version 1.0. // http://www.boost.org/users/license.html #ifndef BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_DYNAMIC_GEOMETRY_CONCEPT_HPP #define BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_DYNAMIC_GEOMETRY_CONCEPT_HPP #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include namespace boost { namespace geometry { namespace concepts { namespace detail { template struct GeometryType : concepts::concept_type::type { #ifndef DOXYGEN_NO_CONCEPT_MEMBERS BOOST_CONCEPT_USAGE(GeometryType) { Geometry* dg = nullptr; SubGeometry* sg = nullptr; *dg = std::move(*sg); } #endif // DOXYGEN_NO_CONCEPT_MEMBERS }; template struct GeometryType : concepts::concept_type::type {}; } // namespace detail template struct DynamicGeometry { #ifndef DOXYGEN_NO_CONCEPT_MEMBERS using sequence_t = typename traits::geometry_types::type; BOOST_CONCEPT_ASSERT((detail::GeometryTypes)); BOOST_CONCEPT_USAGE(DynamicGeometry) { Geometry* dg = nullptr; traits::visit::apply([](auto &&) {}, *dg); } #endif // DOXYGEN_NO_CONCEPT_MEMBERS }; template struct ConstDynamicGeometry { #ifndef DOXYGEN_NO_CONCEPT_MEMBERS using sequence_t = typename traits::geometry_types::type; BOOST_CONCEPT_ASSERT((detail::GeometryTypes)); BOOST_CONCEPT_USAGE(ConstDynamicGeometry) { Geometry const* dg = nullptr; traits::visit::apply([](auto &&) {}, *dg); } #endif // DOXYGEN_NO_CONCEPT_MEMBERS }; template struct concept_type { using type = DynamicGeometry; }; template struct concept_type { using type = ConstDynamicGeometry; }; }}} // namespace boost::geometry::concepts #endif // BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_DYNAMIC_GEOMETRY_CONCEPT_HPP