now using the algebraic structure traits; this is the first step towards

automatizing the method the traits are evaluated
This commit is contained in:
Menelaos Karavelas 2010-03-04 19:00:46 +00:00
parent c80efd7f05
commit 7f78f9946e
1 changed files with 19 additions and 2 deletions

View File

@ -38,10 +38,24 @@ CGAL_BEGIN_NAMESPACE
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
// this traits class does support intersecting segments // this traits class does support intersecting segments
template<class R, class MTag = Field_tag>
// the following definition is okay when giving Field_with_sqrt_tag
// for all other tags I need a specialization
template<class R,
class MTag =
typename Algebraic_structure_traits<typename R::FT>::Algebraic_category
/*Field_tag*/>
struct Segment_Delaunay_graph_traits_2 struct Segment_Delaunay_graph_traits_2
: public Segment_Delaunay_graph_traits_base_2<R,MTag,Tag_true> {}; : public Segment_Delaunay_graph_traits_base_2<R,MTag,Tag_true> {};
template<class R>
struct Segment_Delaunay_graph_traits_2<R,Field_with_kth_root_tag>
: public Segment_Delaunay_graph_traits_base_2<R,Field_with_sqrt_tag,Tag_true> {};
template<class R>
struct Segment_Delaunay_graph_traits_2<R,Field_with_root_of_tag>
: public Segment_Delaunay_graph_traits_base_2<R,Field_with_sqrt_tag,Tag_true> {};
template<class R> template<class R>
struct Segment_Delaunay_graph_traits_2<R,Field_tag> struct Segment_Delaunay_graph_traits_2<R,Field_tag>
: public Segment_Delaunay_graph_traits_base_2<R,Integral_domain_without_division_tag,Tag_true> {}; : public Segment_Delaunay_graph_traits_base_2<R,Integral_domain_without_division_tag,Tag_true> {};
@ -92,7 +106,10 @@ struct Segment_Delaunay_graph_traits_2<Filtered_kernel<R>,Field_with_sqrt_tag>
//========================================================================= //=========================================================================
// this traits class does NOT support intersecting segments // this traits class does NOT support intersecting segments
template<class R, class MTag = Integral_domain_without_division_tag> template<class R,
class MTag =
typename Algebraic_structure_traits<typename R::FT>::Algebraic_category
/*Integral_domain_without_division_tag*/>
struct Segment_Delaunay_graph_traits_without_intersections_2 struct Segment_Delaunay_graph_traits_without_intersections_2
: public Segment_Delaunay_graph_traits_base_2<R,MTag,Tag_false> {}; : public Segment_Delaunay_graph_traits_base_2<R,MTag,Tag_false> {};