semigroup_base.hh

00001 // semigroup_base.hh: this file is part of the Vaucanson project.
00002 //
00003 // Vaucanson, a generic library for finite state machines.
00004 //
00005 // Copyright (C) 2001, 2002, 2003, 2004, 2005 The Vaucanson Group.
00006 //
00007 // This program is free software; you can redistribute it and/or
00008 // modify it under the terms of the GNU General Public License
00009 // as published by the Free Software Foundation; either version 2
00010 // of the License, or (at your option) any later version.
00011 //
00012 // The complete GNU General Public Licence Notice can be found as the
00013 // `COPYING' file in the root directory.
00014 //
00015 // The Vaucanson Group consists of people listed in the `AUTHORS' file.
00016 //
00017 #ifndef VCSN_ALGEBRA_CONCEPT_SEMIGROUP_BASE_HH
00018 # define VCSN_ALGEBRA_CONCEPT_SEMIGROUP_BASE_HH
00019 
00020 # include <vaucanson/design_pattern/design_pattern.hh>
00021 
00022 namespace vcsn {
00023 
00024   namespace algebra {
00025 
00029 
00030 
00031     struct mul_kind
00032     {};
00033 
00036     struct add_kind
00037     {};
00038 
00044     template<class Self>
00045     struct SemigroupBase : Structure<Self>
00046     {
00047     protected:
00049       SemigroupBase();
00050 
00052       SemigroupBase(const SemigroupBase& other);
00053     };
00054 
00058   } // algebra
00059 
00063   /*-------------------------------------.
00064   | dynamic_traits<SemigroupBase<Self> > |
00065   `-------------------------------------*/
00066 
00067   template<class Self>
00068   struct dynamic_traits<algebra::SemigroupBase<Self> >
00069     : dynamic_traits<Structure<Self> >
00070   { };
00071 
00072   template<typename S>
00073   struct virtual_types<algebra::SemigroupBase<S> >
00074     : virtual_types<Structure<S> >
00075   {
00076     typedef undefined_type semigroup_kind;
00077   };
00078 
00079 
00080   /*-----------------------------------.
00081   | MetaElement<SemigroupBase<Self>,T> |
00082   `-----------------------------------*/
00083 
00085   template<class Self, typename T>
00086   struct MetaElement<algebra::SemigroupBase<Self>, T>
00087     : MetaElement<Structure<Self>, T>
00088   {
00089   protected:
00091     MetaElement();
00092 
00094     MetaElement(const MetaElement& other);
00095   };
00096 
00100 } // vcsn
00101 
00102 # ifndef VCSN_USE_INTERFACE_ONLY
00103 #  include <vaucanson/algebra/concept/semigroup_base.hxx>
00104 # endif // VCSN_USE_INTERFACE_ONLY
00105 
00106 #endif // ! VCSN_ALGEBRA_CONCEPT_SEMIGROUP_BASE_HH

Generated on Fri Jul 28 12:18:51 2006 for Vaucanson by  doxygen 1.4.6