|
BWAPI
|
00001 // Copyright (c) 2003,2004,2005,2006 INRIA Sophia-Antipolis (France) and 00002 // Notre Dame University (U.S.A.). All rights reserved. 00003 // 00004 // This file is part of CGAL (www.cgal.org); you may redistribute it under 00005 // the terms of the Q Public License version 1.0. 00006 // See the file LICENSE.QPL distributed with CGAL. 00007 // 00008 // Licensees holding a valid commercial license may use this file in 00009 // accordance with the commercial license agreement provided with the software. 00010 // 00011 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 00012 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 00013 // 00014 // $URL: svn+ssh://scm.gforge.inria.fr/svn/cgal/branches/CGAL-3.5-branch/Segment_Delaunay_graph_2/include/CGAL/Segment_Delaunay_graph_2/Kernel_wrapper_2.h $ 00015 // $Id: Kernel_wrapper_2.h 32830 2006-07-31 13:25:07Z mkaravel $ 00016 // 00017 // 00018 // Author(s) : Menelaos Karavelas <mkaravel@cse.nd.edu> 00019 00020 00021 00022 #ifndef CGAL_SEGMENT_DELAUNAY_GRAPH_2_KERNEL_WRAPPER_2_H 00023 #define CGAL_SEGMENT_DELAUNAY_GRAPH_2_KERNEL_WRAPPER_2_H 00024 00025 #include <CGAL/Segment_Delaunay_graph_2/basic.h> 00026 00027 #include <CGAL/Segment_Delaunay_graph_2/Constructions_C2.h> 00028 00029 #include <CGAL/Segment_Delaunay_graph_site_2.h> 00030 #include <CGAL/Segment_Delaunay_graph_simple_site_2.h> 00031 00032 00033 00034 CGAL_BEGIN_NAMESPACE 00035 00036 CGAL_SEGMENT_DELAUNAY_GRAPH_2_BEGIN_NAMESPACE 00037 00038 namespace Internal { 00039 00040 template<class K, class ITag> struct SDG_Which_site; 00041 00042 // If the ITag is Tag_true we fully support intersections and 00043 // therefore we need the full-fletched site. 00044 template<class K> 00045 struct SDG_Which_site<K,Tag_true> 00046 { 00047 typedef K Kernel; 00048 typedef Tag_true Intersections_tag; 00049 00050 typedef CGAL::Segment_Delaunay_graph_site_2<K> Site_2; 00051 00052 typedef Construct_sdg_site_2<Site_2,Intersections_tag> 00053 Construct_site_2; 00054 }; 00055 00056 // If the ITag is Tag_false we are happy with the simple site. 00057 template<class K> 00058 struct SDG_Which_site<K,Tag_false> 00059 { 00060 typedef K Kernel; 00061 typedef Tag_false Intersections_tag; 00062 00063 typedef CGAL::Segment_Delaunay_graph_simple_site_2<K> Site_2; 00064 00065 typedef Construct_sdg_site_2<Site_2,Intersections_tag> 00066 Construct_site_2; 00067 }; 00068 00069 } // namespace Internal 00070 00071 00072 00073 template<class Kernel_base_2, class ITag> 00074 class Kernel_wrapper_2 00075 : public Kernel_base_2 00076 { 00077 public: 00078 typedef Kernel_base_2 Kernel_base; 00079 typedef ITag Intersections_tag; 00080 00081 typedef typename 00082 Internal::SDG_Which_site<Kernel_base,Intersections_tag>::Site_2 Site_2; 00083 00084 typedef typename 00085 Internal::SDG_Which_site<Kernel_base,Intersections_tag>::Construct_site_2 00086 Construct_site_2; 00087 }; 00088 00089 00090 CGAL_SEGMENT_DELAUNAY_GRAPH_2_END_NAMESPACE 00091 00092 CGAL_END_NAMESPACE 00093 00094 00095 #endif // CGAL_SEGMENT_DELAUNAY_GRAPH_2_KERNEL_WRAPPER_2_H
1.7.6.1