annotate DEPENDENCIES/generic/include/boost/geometry/strategies/concepts/convex_hull_concept.hpp @ 133:4acb5d8d80b6 tip

Don't fail environmental check if README.md exists (but .txt and no-suffix don't)
author Chris Cannam
date Tue, 30 Jul 2019 12:25:44 +0100
parents c530137014c0
children
rev   line source
Chris@16 1 // Boost.Geometry (aka GGL, Generic Geometry Library)
Chris@16 2
Chris@16 3 // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
Chris@16 4 // Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
Chris@16 5 // Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
Chris@16 6
Chris@101 7 // This file was modified by Oracle on 2014.
Chris@101 8 // Modifications copyright (c) 2014 Oracle and/or its affiliates.
Chris@101 9
Chris@101 10 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
Chris@101 11
Chris@16 12 // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
Chris@16 13 // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
Chris@16 14
Chris@16 15 // Use, modification and distribution is subject to the Boost Software License,
Chris@16 16 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
Chris@16 17 // http://www.boost.org/LICENSE_1_0.txt)
Chris@16 18
Chris@16 19 #ifndef BOOST_GEOMETRY_STRATEGIES_CONCEPTS_CONVEX_HULL_CONCEPT_HPP
Chris@16 20 #define BOOST_GEOMETRY_STRATEGIES_CONCEPTS_CONVEX_HULL_CONCEPT_HPP
Chris@16 21
Chris@16 22
Chris@16 23 #include <vector>
Chris@16 24
Chris@16 25 #include <boost/concept_check.hpp>
Chris@16 26
Chris@16 27
Chris@16 28 namespace boost { namespace geometry { namespace concept
Chris@16 29 {
Chris@16 30
Chris@16 31
Chris@16 32 /*!
Chris@16 33 \brief Checks strategy for convex_hull
Chris@16 34 \ingroup convex_hull
Chris@16 35 */
Chris@16 36 template <typename Strategy>
Chris@16 37 class ConvexHullStrategy
Chris@16 38 {
Chris@16 39 #ifndef DOXYGEN_NO_CONCEPT_MEMBERS
Chris@16 40
Chris@16 41 // 1) must define state_type
Chris@16 42 typedef typename Strategy::state_type state_type;
Chris@16 43
Chris@16 44 // 2) must define point_type
Chris@16 45 typedef typename Strategy::point_type point_type;
Chris@16 46
Chris@16 47 // 3) must define geometry_type
Chris@16 48 typedef typename Strategy::geometry_type geometry_type;
Chris@16 49
Chris@16 50 struct check_methods
Chris@16 51 {
Chris@16 52 static void apply()
Chris@16 53 {
Chris@101 54 Strategy const* str = 0;
Chris@16 55
Chris@101 56 state_type* st = 0;
Chris@101 57 geometry_type* sp = 0;
Chris@101 58 std::vector<point_type> *v = 0;
Chris@16 59
Chris@16 60 // 4) must implement a method apply, iterating over a range
Chris@16 61 str->apply(*sp, *st);
Chris@16 62
Chris@16 63 // 5) must implement a method result, with an output iterator
Chris@101 64 str->result(*st, std::back_inserter(*v), true, true);
Chris@16 65 }
Chris@16 66 };
Chris@16 67
Chris@16 68 public :
Chris@16 69 BOOST_CONCEPT_USAGE(ConvexHullStrategy)
Chris@16 70 {
Chris@16 71 check_methods::apply();
Chris@16 72 }
Chris@16 73 #endif
Chris@16 74 };
Chris@16 75
Chris@16 76
Chris@16 77 }}} // namespace boost::geometry::concept
Chris@16 78
Chris@16 79
Chris@16 80 #endif // BOOST_GEOMETRY_STRATEGIES_CONCEPTS_CONVEX_HULL_CONCEPT_HPP