Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:36:52

0001 // Boost.Geometry (aka GGL, Generic Geometry Library)
0002 
0003 // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
0004 // Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
0005 // Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
0006 // Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
0007 
0008 // This file was modified by Oracle on 2020.
0009 // Modifications copyright (c) 2020 Oracle and/or its affiliates.
0010 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
0011 
0012 // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
0013 // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
0014 
0015 // Use, modification and distribution is subject to the Boost Software License,
0016 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
0017 // http://www.boost.org/LICENSE_1_0.txt)
0018 
0019 #ifndef BOOST_GEOMETRY_STRATEGY_AREA_HPP
0020 #define BOOST_GEOMETRY_STRATEGY_AREA_HPP
0021 
0022 
0023 #include <boost/geometry/core/coordinate_type.hpp>
0024 #include <boost/geometry/core/static_assert.hpp>
0025 
0026 #include <boost/geometry/util/select_most_precise.hpp>
0027 
0028 
0029 namespace boost { namespace geometry
0030 {
0031 
0032 
0033 namespace strategy { namespace area
0034 {
0035 
0036 
0037 #ifndef DOXYGEN_NO_DETAIL
0038 namespace detail
0039 {
0040 
0041 // If user specified a CalculationType, use that type, whatever it is
0042 //   and whatever the Geometry is.
0043 // Else, use Geometry's coordinate-type promoted to double if needed.
0044 template
0045 <
0046     typename Geometry,
0047     typename CalculationType
0048 >
0049 struct result_type
0050 {
0051     typedef CalculationType type;
0052 };
0053 
0054 template
0055 <
0056     typename Geometry
0057 >
0058 struct result_type<Geometry, void>
0059     : select_most_precise
0060         <
0061             typename coordinate_type<Geometry>::type,
0062             double
0063         >
0064 {};
0065 
0066 } // namespace detail
0067 #endif // DOXYGEN_NO_DETAIL
0068 
0069 
0070 namespace services
0071 {
0072 
0073 /*!
0074     \brief Traits class binding a default area strategy to a coordinate system
0075     \ingroup area
0076     \tparam Tag tag of coordinate system
0077 */
0078 template <typename Tag>
0079 struct default_strategy
0080 {
0081     BOOST_GEOMETRY_STATIC_ASSERT_FALSE(
0082         "Not implemented for this coordinate system.",
0083         Tag);
0084 };
0085 
0086 
0087 } // namespace services
0088 
0089 }} // namespace strategy::area
0090 
0091 
0092 }} // namespace boost::geometry
0093 
0094 #endif // BOOST_GEOMETRY_STRATEGY_AREA_HPP