From 7a14df8cae3af7ab16f1d75f41d5683a698c1feb Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Thu, 7 Mar 2019 17:29:14 +0100 Subject: [PATCH 1/2] Range and Segment Trees: Sync code and doc --- .../CGAL/Range_segment_tree_traits.h | 36 +++++++++---------- .../SearchStructures/PackageDescription.txt | 12 +++---- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h index 9f1e6414b86..638b764c33a 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h @@ -4,13 +4,13 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Range_segment_tree_traits_set_2` is a range and segment tree traits class for the +The class `Range_segment_tree_set_traits_2` is a range and segment tree traits class for the 2-dimensional point class from the \cgal kernel. The class is parameterized with a representation class `R`. */ template< typename R > -class Range_segment_tree_traits_set_2 { +class Range_segment_tree_set_traits_2 { public: /// \name Types @@ -28,7 +28,7 @@ std::pair Interval; /// @} -}; /* end Range_segment_tree_traits_set_2 */ +}; /* end Range_segment_tree_set_traits_2 */ } /* end namespace CGAL */ namespace CGAL { @@ -36,13 +36,13 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Range_segment_tree_traits_set_3` is a range and segment tree traits class for the 3-dimensional +The class `Range_segment_tree_set_traits_3` is a range and segment tree traits class for the 3-dimensional point class from the \cgal kernel. The class is parameterized with a representation class `R`. */ template< typename R > -class Range_segment_tree_traits_set_3 { +class Range_segment_tree_set_traits_3 { public: /// \name Types @@ -60,7 +60,7 @@ std::pair Interval; /// @} -}; /* end Range_segment_tree_traits_set_3 */ +}; /* end Range_segment_tree_set_traits_3 */ } /* end namespace CGAL */ namespace CGAL { @@ -68,7 +68,7 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Range_tree_traits_map_2` is a range tree traits class for the +The class `Range_tree_map_traits_2` is a range tree traits class for the 2-dimensional point class from the \cgal kernel, where data of type `T` is associated to each key. The class is parameterized with a representation class `R` and the type of @@ -76,7 +76,7 @@ the associated data `T`. */ template< typename R, typename T > -class Range_tree_traits_map_2 { +class Range_tree_map_traits_2 { public: /// \name Types @@ -94,7 +94,7 @@ std::pair Interval; /// @} -}; /* end Range_tree_traits_map_2 */ +}; /* end Range_tree_map_traits_2 */ } /* end namespace CGAL */ namespace CGAL { @@ -102,7 +102,7 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Range_tree_traits_map_3` is a range and segment tree traits class for the 3-dimensional +The class `Range_tree_map_traits_3` is a range and segment tree traits class for the 3-dimensional point class from the \cgal kernel, where data of type `T` is associated to each key. The class is parameterized with a representation class `R` and the type of @@ -110,7 +110,7 @@ the associated data `T`. */ template< typename R, typename T > -class Range_tree_traits_map_3 { +class Range_tree_map_traits_3 { public: /// \name Types @@ -128,7 +128,7 @@ std::pair Interval; /// @} -}; /* end Range_tree_traits_map_3 */ +}; /* end Range_tree_map_traits_3 */ } /* end namespace CGAL */ namespace CGAL { @@ -136,7 +136,7 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Segment_tree_traits_map_2` is a segment tree traits class for the +The class `Segment_tree_map_traits_2` is a segment tree traits class for the 2-dimensional point class from the \cgal kernel, where data of type `T` is associated to each interval. The class is parameterized with a representation class `R` and the type of @@ -144,7 +144,7 @@ the associated data `T`. */ template< typename R, typename T > -class Segment_tree_traits_map_2 { +class Segment_tree_map_traits_2 { public: /// \name Types @@ -162,7 +162,7 @@ std::pair,T> Interval; /// @} -}; /* end Segment_tree_traits_map_2 */ +}; /* end Segment_tree_map_traits_2 */ } /* end namespace CGAL */ namespace CGAL { @@ -170,7 +170,7 @@ namespace CGAL { /*! \ingroup PkgSearchStructuresTraitsClasses -The class `Segment_tree_traits_map_3` is a segment tree traits class for the 3-dimensional +The class `Segment_tree_map_traits_3` is a segment tree traits class for the 3-dimensional point class from the \cgal kernel, where data of type `T` is associated to each interval. The class is parameterized with a representation class `R` and the type of @@ -178,7 +178,7 @@ the associated data `T`. */ template< typename R, typename T > -class Segment_tree_traits_map_3 { +class Segment_tree_map_traits_3 { public: /// \name Types @@ -196,5 +196,5 @@ std::pair,T> Interval; /// @} -}; /* end Segment_tree_traits_map_3 */ +}; /* end Segment_tree_map_traits_3 */ } /* end namespace CGAL */ diff --git a/SearchStructures/doc/SearchStructures/PackageDescription.txt b/SearchStructures/doc/SearchStructures/PackageDescription.txt index 812e4c10b37..a2f35335bfc 100644 --- a/SearchStructures/doc/SearchStructures/PackageDescription.txt +++ b/SearchStructures/doc/SearchStructures/PackageDescription.txt @@ -42,12 +42,12 @@ and segment trees in the same data structure. \cgalCRPSection{Traits Classes} -- `CGAL::Range_segment_tree_traits_set_2` -- `CGAL::Range_segment_tree_traits_set_3` -- `CGAL::Range_tree_traits_map_2` -- `CGAL::Range_tree_traits_map_3` -- `CGAL::Segment_tree_traits_map_2` -- `CGAL::Segment_tree_traits_map_3` +- `CGAL::Range_segment_tree_set_traits_2` +- `CGAL::Range_segment_tree_set_traits_3` +- `CGAL::Range_tree_map_traits_2` +- `CGAL::Range_tree_map_traits_3` +- `CGAL::Segment_tree_map_traits_2` +- `CGAL::Segment_tree_map_traits_3` - `CGAL::tree_interval_traits` - `CGAL::tree_point_traits` From d0d5251cb6f49dc107a6433ab202a7ec725f954d Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Fri, 8 Mar 2019 09:29:28 +0100 Subject: [PATCH 2/2] Add \cgalHHasModel and \cgalModels and backtick (even in Triangulation_3) --- .../CGAL/Range_segment_tree_traits.h | 36 ++++++++++++------- .../Concepts/RangeSegmentTreeTraits_k.h | 10 +++++- .../DelaunayTriangulationCellBase_3.h | 6 ++-- .../Concepts/DelaunayTriangulationTraits_3.h | 10 +++--- ...lationCellBaseWithWeightedCircumcenter_3.h | 2 +- .../Concepts/RegularTriangulationCellBase_3.h | 4 +-- .../RegularTriangulationVertexBase_3.h | 2 +- .../TriangulationCellBaseWithInfo_3.h | 2 +- .../Concepts/TriangulationCellBase_3.h | 6 ++-- .../TriangulationVertexBaseWithInfo_3.h | 2 +- .../Concepts/TriangulationVertexBase_3.h | 4 +-- 11 files changed, 52 insertions(+), 32 deletions(-) diff --git a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h index 638b764c33a..52350d1c803 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h @@ -8,6 +8,8 @@ The class `Range_segment_tree_set_traits_2` is a range and segment tree traits c 2-dimensional point class from the \cgal kernel. The class is parameterized with a representation class `R`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R > class Range_segment_tree_set_traits_2 { @@ -19,12 +21,12 @@ public: /*! */ -Point_2 Key; + typedef R::Point_2 Key; /*! */ -std::pair Interval; +typedef std::pair Interval; /// @} @@ -40,6 +42,8 @@ The class `Range_segment_tree_set_traits_3` is a range and segment tree traits c point class from the \cgal kernel. The class is parameterized with a representation class `R`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R > class Range_segment_tree_set_traits_3 { @@ -51,12 +55,12 @@ public: /*! */ -Point_3 Key; + typedef R::Point_3 Key; /*! */ -std::pair Interval; +typedef std::pair Interval; /// @} @@ -74,6 +78,8 @@ type `T` is associated to each key. The class is parameterized with a representation class `R` and the type of the associated data `T`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R, typename T > class Range_tree_map_traits_2 { @@ -85,12 +91,12 @@ public: /*! */ -std::pair Key; +typedef std::pair Key; /*! */ -std::pair Interval; +typedef std::pair Interval; /// @} @@ -108,6 +114,8 @@ type `T` is associated to each key. The class is parameterized with a representation class `R` and the type of the associated data `T`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R, typename T > class Range_tree_map_traits_3 { @@ -119,12 +127,12 @@ public: /*! */ -std::pair Key; +typedef std::pair Key; /*! */ -std::pair Interval; +typedef std::pair Interval; /// @} @@ -142,6 +150,8 @@ type `T` is associated to each interval. The class is parameterized with a representation class `R` and the type of the associated data `T`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R, typename T > class Segment_tree_map_traits_2 { @@ -153,12 +163,12 @@ public: /*! */ -R::Point_2 Key; +typedef R::Point_2 Key; /*! */ -std::pair,T> Interval; +typedef std::pair,T> Interval; /// @} @@ -176,6 +186,8 @@ type `T` is associated to each interval. The class is parameterized with a representation class `R` and the type of the associated data `T`. +\cgalModels `RangeSegmentTreeTraits_k` + */ template< typename R, typename T > class Segment_tree_map_traits_3 { @@ -187,12 +199,12 @@ public: /*! */ -std::pair Key; +typedef std::pair Key; /*! */ -std::pair,T> Interval; +typedef std::pair,T> Interval; /// @} diff --git a/SearchStructures/doc/SearchStructures/Concepts/RangeSegmentTreeTraits_k.h b/SearchStructures/doc/SearchStructures/Concepts/RangeSegmentTreeTraits_k.h index 3e172861b92..fc658b1fbaa 100644 --- a/SearchStructures/doc/SearchStructures/Concepts/RangeSegmentTreeTraits_k.h +++ b/SearchStructures/doc/SearchStructures/Concepts/RangeSegmentTreeTraits_k.h @@ -8,6 +8,14 @@ type information of the keys and intervals. Further more, they define function o the keys and intervals, and provide comparison functions that are needed for window queries. + +\cgalHasModel `CGAL::Range_segment_tree_set_traits_2` +\cgalHasModel `CGAL::Range_segment_tree_set_traits_3` +\cgalHasModel `CGAL::Range_tree_map_traits_2` +\cgalHasModel `CGAL::Range_tree_map_traits_3` +\cgalHasModel `CGAL::Segment_tree_map_traits_2` +\cgalHasModel `CGAL::Segment_tree_map_traits_3` + \cgalHeading{Example} The following piece of code gives an example of how a traits class @@ -122,7 +130,7 @@ typedef unspecified_type high_i; /*! function object providing an `operator()` that takes two arguments argument \f$ a\f$, \f$ b\f$ of type `Key_i` and returns -true if \f$ a