00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef VCSN_ALGEBRA_IMPLEMENTATION_FREE_MONOID_WORDS_HH
00018 # define VCSN_ALGEBRA_IMPLEMENTATION_FREE_MONOID_WORDS_HH
00019
00020 # include <string>
00021 # include <vaucanson/algebra/concept/freemonoid_base.hh>
00022 # include <vaucanson/misc/unique.hh>
00023
00024 namespace vcsn {
00025
00026 namespace algebra {
00027
00031
00032
00033
00035 template<typename A>
00036 struct FreeMonoid
00037 : FreeMonoidBase<FreeMonoid<A> >
00038 {
00039 typedef A alphabets_elt_t;
00040
00042 FreeMonoid(const A& a);
00043
00045 FreeMonoid(const FreeMonoid& w);
00046
00049 A& alphabet();
00050
00052 const A& alphabet() const;
00053
00054 protected:
00055 A alph_;
00056 };
00057
00058 template<typename A>
00059 bool operator==(const FreeMonoid<A>& a,
00060 const FreeMonoid<A>& b);
00061
00062
00065 };
00066
00070
00071
00072
00074 template<typename A>
00075 struct dynamic_traits<algebra::FreeMonoid<A> >
00076 : dynamic_traits<algebra::FreeMonoidBase<algebra::FreeMonoid<A> > >
00077 {
00079 static const bool ret = A::dynamic;
00080 };
00081
00082
00083
00084
00087 template<typename A, typename T>
00088 struct MetaElement<algebra::FreeMonoid<A>, T>
00089 : MetaElement<algebra::FreeMonoidBase<algebra::FreeMonoid<A> >, T>
00090 {};
00091
00094 template <class A>
00095 struct virtual_types<algebra::FreeMonoid<A> >
00096 : virtual_types<algebra::FreeMonoidBase<algebra::FreeMonoid<A> > >
00097 {
00099 typedef algebra::mul_kind semigroup_kind;
00100
00101 typedef A alphabet_t;
00102 };
00103
00110 enum op_choose_max_word_length_t { op_choose_max_word_length = 32 };
00111
00112 }
00113
00114 # ifndef VCSN_USE_INTERFACE_ONLY
00115 # include <vaucanson/algebra/implementation/free_monoid/words.hxx>
00116 # endif // VCSN_USE_INTERFACE_ONLY
00117
00118 #endif // ! VCSN_ALGEBRA_IMPLEMENTATION_FREE_MONOID_WORDS_HH