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
00066 };
00067
00071
00072
00073
00075 template<typename A>
00076 struct dynamic_traits<algebra::FreeMonoid<A> >
00077 : dynamic_traits<algebra::FreeMonoidBase<algebra::FreeMonoid<A> > >
00078 {
00080 static const bool ret = A::dynamic;
00081 };
00082
00083
00084
00085
00088 template<typename A, typename T>
00089 struct MetaElement<algebra::FreeMonoid<A>, T>
00090 : MetaElement<algebra::FreeMonoidBase<algebra::FreeMonoid<A> >, T>
00091 {};
00092
00096 template <class A>
00097 struct virtual_types<algebra::FreeMonoid<A> >
00098 : virtual_types<algebra::FreeMonoidBase<algebra::FreeMonoid<A> > >
00099 {
00101 typedef algebra::mul_kind semigroup_kind;
00102
00103 typedef A alphabet_t;
00104 };
00105
00112 enum op_choose_max_word_length_t { op_choose_max_word_length = 32 };
00113
00114 }
00115
00116 # if !defined VCSN_USE_INTERFACE_ONLY || defined VCSN_USE_LIB
00117 # include <vaucanson/algebra/implementation/free_monoid/words.hxx>
00118 # endif // VCSN_USE_INTERFACE_ONLY
00119
00120 #endif // ! VCSN_ALGEBRA_IMPLEMENTATION_FREE_MONOID_WORDS_HH