ring.hpp 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. // Boost.Geometry (aka GGL, Generic Geometry Library)
  2. // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
  3. // Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
  4. // Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
  5. // Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
  6. // (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
  7. // Use, modification and distribution is subject to the Boost Software License,
  8. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  9. // http://www.boost.org/LICENSE_1_0.txt)
  10. #ifndef BOOST_GEOMETRY_GEOMETRIES_REGISTER_RING_HPP
  11. #define BOOST_GEOMETRY_GEOMETRIES_REGISTER_RING_HPP
  12. #include <boost/geometry/core/tag.hpp>
  13. #include <boost/geometry/core/tags.hpp>
  14. /*!
  15. \brief \brief_macro{ring}
  16. \ingroup register
  17. \details \details_macro{BOOST_GEOMETRY_REGISTER_RING, ring} The
  18. ring may contain template parameters, which must be specified then.
  19. \param Ring \param_macro_type{ring}
  20. \qbk{
  21. [heading Example]
  22. [register_ring]
  23. [register_ring_output]
  24. }
  25. */
  26. #define BOOST_GEOMETRY_REGISTER_RING(Ring) \
  27. namespace boost { namespace geometry { namespace traits { \
  28. template<> struct tag<Ring> { typedef ring_tag type; }; \
  29. }}}
  30. /*!
  31. \brief \brief_macro{templated ring}
  32. \ingroup register
  33. \details \details_macro{BOOST_GEOMETRY_REGISTER_RING_TEMPLATED, templated ring}
  34. \details_macro_templated{ring, point}
  35. \param Ring \param_macro_type{ring (without template parameters)}
  36. \qbk{
  37. [heading Example]
  38. [register_ring_templated]
  39. [register_ring_templated_output]
  40. }
  41. */
  42. #define BOOST_GEOMETRY_REGISTER_RING_TEMPLATED(Ring) \
  43. namespace boost { namespace geometry { namespace traits { \
  44. template<typename P> struct tag< Ring<P> > { typedef ring_tag type; }; \
  45. }}}
  46. #endif // BOOST_GEOMETRY_GEOMETRIES_REGISTER_RING_HPP