Chris@102: // Boost.Geometry (aka GGL, Generic Geometry Library) Chris@102: Chris@102: // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands. Chris@102: // Copyright (c) 2008-2012 Bruno Lalande, Paris, France. Chris@102: // Copyright (c) 2009-2012 Mateusz Loskot, London, UK. Chris@102: Chris@102: // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library Chris@102: // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands. Chris@102: Chris@102: // Use, modification and distribution is subject to the Boost Software License, Chris@102: // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at Chris@102: // http://www.boost.org/LICENSE_1_0.txt) Chris@102: Chris@102: Chris@102: #ifndef BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_MULTI_LINESTRING_CONCEPT_HPP Chris@102: #define BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_MULTI_LINESTRING_CONCEPT_HPP Chris@102: Chris@102: Chris@102: #include Chris@102: #include Chris@102: #include Chris@102: Chris@102: Chris@102: #include Chris@102: Chris@102: Chris@102: namespace boost { namespace geometry { namespace concept Chris@102: { Chris@102: Chris@102: Chris@102: /*! Chris@102: \brief multi-linestring concept Chris@102: \ingroup concepts Chris@102: \par Formal definition: Chris@102: The multi linestring concept is defined as following: Chris@102: - there must be a specialization of traits::tag defining multi_linestring_tag as Chris@102: type Chris@102: - it must behave like a Boost.Range Chris@102: - its range value must fulfil the Linestring concept Chris@102: Chris@102: */ Chris@102: template Chris@102: class MultiLinestring Chris@102: { Chris@102: #ifndef DOXYGEN_NO_CONCEPT_MEMBERS Chris@102: typedef typename boost::range_value::type linestring_type; Chris@102: Chris@102: BOOST_CONCEPT_ASSERT( (concept::Linestring) ); Chris@102: BOOST_CONCEPT_ASSERT( (boost::RandomAccessRangeConcept) ); Chris@102: Chris@102: Chris@102: public : Chris@102: Chris@102: BOOST_CONCEPT_USAGE(MultiLinestring) Chris@102: { Chris@102: Geometry* mls = 0; Chris@102: traits::clear::apply(*mls); Chris@102: traits::resize::apply(*mls, 0); Chris@102: linestring_type* ls = 0; Chris@102: traits::push_back::apply(*mls, *ls); Chris@102: } Chris@102: #endif Chris@102: }; Chris@102: Chris@102: Chris@102: /*! Chris@102: \brief concept for multi-linestring (const version) Chris@102: \ingroup const_concepts Chris@102: */ Chris@102: template Chris@102: class ConstMultiLinestring Chris@102: { Chris@102: #ifndef DOXYGEN_NO_CONCEPT_MEMBERS Chris@102: typedef typename boost::range_value::type linestring_type; Chris@102: Chris@102: BOOST_CONCEPT_ASSERT( (concept::ConstLinestring) ); Chris@102: BOOST_CONCEPT_ASSERT( (boost::RandomAccessRangeConcept) ); Chris@102: Chris@102: Chris@102: public : Chris@102: Chris@102: BOOST_CONCEPT_USAGE(ConstMultiLinestring) Chris@102: { Chris@102: } Chris@102: #endif Chris@102: }; Chris@102: Chris@102: }}} // namespace boost::geometry::concept Chris@102: Chris@102: Chris@102: #endif // BOOST_GEOMETRY_GEOMETRIES_CONCEPTS_MULTI_LINESTRING_CONCEPT_HPP