BWAPI
|
00001 // Copyright (c) 2006 Tel-Aviv University (Israel). 00002 // 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/Arrangement_on_surface_2/include/CGAL/Arr_enums.h $ 00015 // $Id: Arr_enums.h 49772 2009-06-03 21:25:53Z eric $ 00016 // 00017 // 00018 // Author(s): Ron Wein <wein@post.tau.ac.il> 00019 // Efi Fogel <efif@post.tau.ac.il> 00020 00021 #ifndef CGAL_ARR_ENUM_H 00022 #define CGAL_ARR_ENUM_H 00023 00028 #include <CGAL/enum.h> 00029 00030 CGAL_BEGIN_NAMESPACE 00031 00035 enum Arr_curve_end 00036 { 00037 ARR_MIN_END, 00038 ARR_MAX_END 00039 }; 00040 00042 template< class OutputStream > 00043 inline 00044 OutputStream& operator<<( 00045 OutputStream& os, 00046 const Arr_curve_end& ce) { 00047 00048 switch(ce) { 00049 case CGAL::ARR_MIN_END: 00050 os << "ARR_MIN_END"; 00051 break; 00052 case CGAL::ARR_MAX_END: 00053 os << "ARR_MAX_END"; 00054 break; 00055 default: 00056 CGAL_error_msg("bogus curve end"); 00057 } 00058 return os; 00059 } 00060 00061 00067 enum Arr_halfedge_direction 00068 { 00069 ARR_LEFT_TO_RIGHT = -1, 00070 ARR_RIGHT_TO_LEFT = 1 00071 }; 00072 00074 template< class OutputStream > 00075 inline 00076 OutputStream& operator<<( 00077 OutputStream& os, 00078 const Arr_halfedge_direction& dir) { 00079 00080 switch(dir) { 00081 case CGAL::ARR_LEFT_TO_RIGHT: 00082 os << "ARR_LEFT_TO_RIGHT"; 00083 break; 00084 case CGAL::ARR_RIGHT_TO_LEFT: 00085 os << "ARR_RIGHT_TO_LEFT"; 00086 break; 00087 default: 00088 CGAL_error_msg("bogus halfedge direction"); 00089 } 00090 return os; 00091 } 00092 00098 enum Arr_boundary_type { 00099 ARR_OBLIVIOUS = 0, 00100 ARR_OPEN, 00101 ARR_CLOSED, 00102 ARR_CONTRACTION, 00103 ARR_IDENTIFICATION, 00104 }; 00105 00107 template< class OutputStream > 00108 inline 00109 OutputStream& operator<<( 00110 OutputStream& os, 00111 const Arr_boundary_type& bt) { 00112 00113 switch(bt) { 00114 case CGAL::ARR_OPEN: 00115 os << "ARR_OPEN"; 00116 break; 00117 case CGAL::ARR_CLOSED: 00118 os << "ARR_CLOSED"; 00119 break; 00120 case CGAL::ARR_CONTRACTION: 00121 os << "ARR_CONTRACTION"; 00122 break; 00123 case CGAL::ARR_IDENTIFICATION: 00124 os << "ARR_IDENTIFICATION"; 00125 break; 00126 case CGAL::ARR_OBLIVIOUS: 00127 os << "ARR_OBLIVIOUS"; 00128 break; 00129 default: 00130 CGAL_error_msg("bogus boundary type"); 00131 } 00132 return os; 00133 } 00134 00135 00139 enum Arr_parameter_space { 00140 ARR_LEFT_BOUNDARY = 0, 00141 ARR_RIGHT_BOUNDARY, 00142 ARR_BOTTOM_BOUNDARY, 00143 ARR_TOP_BOUNDARY, 00144 ARR_INTERIOR 00145 }; 00146 00147 00149 template< class OutputStream > 00150 inline 00151 OutputStream& operator<<( 00152 OutputStream& os, 00153 const Arr_parameter_space& ps) { 00154 00155 switch(ps) { 00156 case CGAL::ARR_LEFT_BOUNDARY: 00157 os << "ARR_LEFT_BOUNDARY"; 00158 break; 00159 case CGAL::ARR_RIGHT_BOUNDARY: 00160 os << "ARR_RIGHT_BOUNDARY"; 00161 break; 00162 case CGAL::ARR_BOTTOM_BOUNDARY: 00163 os << "ARR_BOTTOM_BOUNDARY"; 00164 break; 00165 case CGAL::ARR_TOP_BOUNDARY: 00166 os << "ARR_TOP_BOUNDARY"; 00167 break; 00168 case CGAL::ARR_INTERIOR: 00169 os << "ARR_INTERIOR"; 00170 break; 00171 default: 00172 CGAL_error_msg("bogus parameter space"); 00173 } 00174 return os; 00175 } 00176 00177 00178 CGAL_END_NAMESPACE 00179 00180 #endif 00181