BWAPI
SPAR/AIModule/BWTA/vendors/CGAL/CGAL/Modular_traits.h
Go to the documentation of this file.
00001 // Max-Planck-Institute Saarbruecken (Germany).
00002 // All rights reserved.
00003 //
00004 // This file is part of CGAL (www.cgal.org); you can redistribute it and/or
00005 // modify it under the terms of the GNU Lesser General Public License as
00006 // published by the Free Software Foundation; version 2.1 of the License.
00007 // See the file LICENSE.LGPL distributed with CGAL.
00008 //
00009 // Licensees holding a valid commercial license may use this file in
00010 // accordance with the commercial license agreement provided with the software.
00011 //
00012 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
00013 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
00014 //
00015 // $URL: svn+ssh://scm.gforge.inria.fr/svn/cgal/branches/CGAL-3.5-branch/Modular_arithmetic/include/CGAL/Modular_traits.h $
00016 // $Id: Modular_traits.h 45762 2008-09-25 13:24:05Z hemmer $
00017 //
00018 // Author(s)     : Michael Hemmer
00019 
00020 #ifndef CGAL_MODULAR_TRAITS_H
00021 #define CGAL_MODULAR_TRAITS_H 1
00022 
00023 #include <CGAL/basic.h>
00024 #include <CGAL/Residue.h>
00025 #include <CGAL/Modular_arithmetic/Residue_type.h>
00026 #include <vector>
00027 
00028 
00029 namespace CGAL { 
00030 
00031 
00040 template<class NT_>
00041 class Modular_traits{
00042 public: 
00043     typedef NT_ NT;
00044     typedef ::CGAL::Tag_false Is_modularizable;
00045     typedef ::CGAL::Null_functor Residue_type;
00046     typedef ::CGAL::Null_functor Modular_image;  
00047     typedef ::CGAL::Null_functor Modular_image_representative;    
00048 };
00049 
00050 template <class NT>
00051 inline
00052 typename CGAL::Modular_traits<NT>::Residue_type 
00053 modular_image(const NT& x){
00054     typename CGAL::Modular_traits<NT>::Modular_image modular_image;
00055     return modular_image(x);
00056 }
00057 
00058 }
00059 #endif //#ifnedef CGAL_MODULAR_TRAITS_H 1
00060  
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines