17 #ifndef VCSN_ALGEBRA_IMPLEMENTATION_SERIES_RAT_DISPATCH_VISITOR_HH
18 # define VCSN_ALGEBRA_IMPLEMENTATION_SERIES_RAT_DISPATCH_VISITOR_HH
20 # include <vaucanson/algebra/implementation/series/rat/exp.hh>
29 template <
class Matcher,
class Mono
id,
class Semiring>
30 class DispatchVisitor :
31 public rat::DefaultMutableNodeVisitor<Monoid, Semiring>
34 typedef Matcher matcher_t;
35 typedef typename Matcher::return_type return_type;
36 typedef Monoid monoid_elt_value_t;
37 typedef Semiring semiring_elt_value_t;
38 typedef rat::Node<monoid_elt_value_t, semiring_elt_value_t> node_t;
40 DispatchVisitor(Matcher& m);
46 product(
const node_t* lhs,
const node_t* rhs);
49 sum(
const node_t* lhs,
const node_t* rhs);
52 star(
const node_t* node);
55 left_weight(
const semiring_elt_value_t& w,
const node_t* node);
58 right_weight(
const semiring_elt_value_t& w,
const node_t* node);
61 constant(
const monoid_elt_value_t& m);
69 return_type get_ret();
73 misc::Deferrer<return_type> ret_;
77 struct DispatchFunction;
85 template <
class M,
class W>
86 struct DispatchFunction< rat::exp<M, W> >
88 template <
class Matcher>
90 typename Matcher::return_type
98 # if !defined VCSN_USE_INTERFACE_ONLY || defined VCSN_USE_LIB
99 # include <vaucanson/algebra/implementation/series/rat/dispatch_visitor.hxx>
100 # endif // ! VCSN_USE_INTERFACE_ONLY
102 #endif // ! VCSN_ALGEBRA_IMPLEMENTATION_SERIES_RAT_DISPATCH_VISITOR_HH