1 // Boost.Geometry (aka GGL, Generic Geometry Library)
3 // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
4 // Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
5 // Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
7 // This file was modified by Oracle on 2014.
8 // Modifications copyright (c) 2014 Oracle and/or its affiliates.
10 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
12 // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
13 // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
15 // Use, modification and distribution is subject to the Boost Software License,
16 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
17 // http://www.boost.org/LICENSE_1_0.txt)
19 #ifndef BOOST_GEOMETRY_UTIL_SELECT_COORDINATE_TYPE_HPP
20 #define BOOST_GEOMETRY_UTIL_SELECT_COORDINATE_TYPE_HPP
23 #include <boost/geometry/core/coordinate_type.hpp>
24 #include <boost/geometry/util/select_most_precise.hpp>
27 namespace boost { namespace geometry
32 \brief Meta-function selecting the most precise coordinate type
36 template <typename T1, typename T2 = void, typename T3 = void>
37 struct select_coordinate_type
39 typedef typename select_most_precise
41 typename coordinate_type<T1>::type,
42 typename coordinate_type<T2>::type,
43 typename coordinate_type<T3>::type
47 template <typename T1, typename T2>
48 struct select_coordinate_type<T1, T2, void>
50 typedef typename select_most_precise
52 typename coordinate_type<T1>::type,
53 typename coordinate_type<T2>::type
57 template <typename T1>
58 struct select_coordinate_type<T1, void, void>
60 typedef typename select_most_precise
62 typename coordinate_type<T1>::type
66 }} // namespace boost::geometry
69 #endif // BOOST_GEOMETRY_UTIL_SELECT_COORDINATE_TYPE_HPP