Commit bfa0d321 authored by Jerome Galtier's avatar Jerome Galtier
Browse files

Add missing automaton makers related to FMP transducers.

	* include/vaucanson/contexts/fmp_transducer_maker.thh,
	* include/vaucanson/contexts/fmp_transducer_maker.thxx: Here
	  (reported by Reuben Thomas).
parent 4aa0bbb8
2008-10-06 Jerome Galtier <jerome.galtier@lrde.epita.fr>
Add missing automaton makers related to FMP transducers.
* include/vaucanson/contexts/fmp_transducer_maker.thh,
* include/vaucanson/contexts/fmp_transducer_maker.thxx: Here
(reported by Reuben Thomas).
2008-10-06 Jerome Galtier <jerome.galtier@lrde.epita.fr>
 
Make FMP transducers headers more in line with RW transducers.
......
......@@ -3,7 +3,7 @@
//
// Vaucanson, a generic library for finite state machines.
//
// Copyright (C) 2005, 2006 The Vaucanson Group.
// Copyright (C) 2005, 2006, 2008 The Vaucanson Group.
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
......@@ -38,6 +38,14 @@ namespace vcsn
const SecondInputIterator second_begin,
const SecondInputIterator second_end);
template <typename S, typename T>
input_projection_automaton_t
make_input_projection_automaton(const Element<S, T>& t);
template <typename S, typename T>
output_projection_automaton_t
make_output_projection_automaton(const Element<S, T>& t);
template <class T1, class T2>
monoid_elt_t make_couple(const T1& first_alphabet,
const T2& second_alphabet,
......
......@@ -3,7 +3,7 @@
//
// Vaucanson, a generic library for finite state machines.
//
// Copyright (C) 2005, 2006 The Vaucanson Group.
// Copyright (C) 2005, 2006, 2008 The Vaucanson Group.
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
......@@ -73,6 +73,32 @@ namespace vcsn
second_alphabet.begin(), second_alphabet.end());
}
template <typename S, typename T>
input_projection_automaton_t
make_input_projection_automaton(const Element<S, T>& transducer)
{
typedef input_projection_automaton_t::set_t set_t;
typedef set_t::series_set_t series_set_t;
set_t
auto_set(series_set_t(transducer.structure().series().
semiring(), transducer.structure().series().
monoid().first_monoid()));
return input_projection_automaton_t(auto_set);
}
template <typename S, typename T>
output_projection_automaton_t
make_output_projection_automaton(const Element<S, T>& transducer)
{
typedef output_projection_automaton_t::set_t set_t;
typedef set_t::series_set_t series_set_t;
set_t
auto_set(series_set_t(transducer.structure().series().
semiring(), transducer.structure().series().
monoid().second_monoid()));
return output_projection_automaton_t(auto_set);
}
template <class FirstIterator, class SecondIterator>
monoid_elt_t make_couple(const FirstIterator first_begin,
const FirstIterator first_end,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment