Back to home page

EIC code displayed by LXR

 
 

    


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

0001 // Boost.Geometry
0002 
0003 // Copyright (c) 2014 Adam Wulkiewicz, Lodz, Poland.
0004 
0005 // Use, modification and distribution is subject to the Boost Software License,
0006 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
0007 // http://www.boost.org/LICENSE_1_0.txt)
0008 
0009 #ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_INTERIOR_ITERATOR_HPP
0010 #define BOOST_GEOMETRY_ALGORITHMS_DETAIL_INTERIOR_ITERATOR_HPP
0011 
0012 #include <boost/range/iterator.hpp>
0013 #include <boost/range/value_type.hpp>
0014 
0015 #include <boost/geometry/core/interior_type.hpp>
0016 
0017 namespace boost { namespace geometry
0018 {
0019 
0020 #ifndef DOXYGEN_NO_DETAIL
0021 namespace detail
0022 {
0023 
0024 /*!
0025 \brief Structure defining the type of interior rings iterator
0026 \note If the Geometry is const, const iterator is defined.
0027 \tparam Geometry \tparam_geometry
0028  */
0029 template <typename Geometry>
0030 struct interior_iterator
0031 {
0032     typedef typename boost::range_iterator
0033         <
0034             typename geometry::interior_type<Geometry>::type
0035         >::type type;
0036 };
0037 
0038 template <typename BaseT, typename T>
0039 struct copy_const
0040 {
0041     typedef T type;
0042 };
0043 
0044 template <typename BaseT, typename T>
0045 struct copy_const<BaseT const, T>
0046 {
0047     typedef T const type;
0048 };
0049 
0050 template <typename Geometry>
0051 struct interior_ring_iterator
0052 {
0053     typedef typename boost::range_iterator
0054         <
0055             typename copy_const
0056                 <
0057                     typename geometry::interior_type<Geometry>::type,
0058                     typename boost::range_value
0059                         <
0060                             typename geometry::interior_type<Geometry>::type
0061                         >::type
0062                 >::type
0063         >::type type;
0064 };
0065 
0066 } // namespace detail
0067 #endif // DOXYGEN_NO_DETAIL
0068 
0069 }} // namespace boost::geometry
0070 
0071 #endif // BOOST_GEOMETRY_ALGORITHMS_DETAIL_INTERIOR_ITERATOR_HPP