Commit 2780bf57 authored by Jérôme Galtier's avatar Jérôme Galtier
Browse files

Update the documentation of the interface.

* doc/doxygen.xsl (user-section): Ignore the "new_" prefix. Do not
print detailed descriptions.
* include/vaucanson/automata/concept/automata_base.hh
(MetaElement<AutomataBase>): Change the grouping and order of
the interface methods.
parent 9f1d60fc
2009-10-09 Jérôme Galtier <jerome.galtier@lrde.epita.fr>
Update the documentation of the interface.
* doc/doxygen.xsl (user-section): Ignore the "new_" prefix. Do not
print detailed descriptions.
* include/vaucanson/automata/concept/automata_base.hh
(MetaElement<AutomataBase>): Change the grouping and order of
the interface methods.
2009-10-09 Jérôme Galtier <jerome.galtier@lrde.epita.fr>
 
Update vcsn-doxygen.sty to the latest version.
......
......@@ -23,9 +23,6 @@
<xsl:with-param name="header" select="'Public Member Functions'" />
</xsl:call-template>
\clearpage
\section{Detailed Description}
<xsl:for-each select="detaileddescription/para/node()"><xsl:apply-templates select="." /></xsl:for-each>
</xsl:template>
<!-- Subgrouping -->
......@@ -42,7 +39,7 @@
type &amp; description \\
\hline
<xsl:for-each select="$selector">
\lstinline|<xsl:value-of select="name" />| &amp; <xsl:for-each select="briefdescription/para/node()"><xsl:apply-templates select="." /></xsl:for-each>\\
\lstinline|<xsl:value-of select="substring(name, 5)" />| &amp; <xsl:for-each select="briefdescription/para/node()"><xsl:apply-templates select="." /></xsl:for-each>\\
</xsl:for-each>
\hline
\end{tabular}
......
......@@ -367,8 +367,6 @@ namespace vcsn {
typedef MetaElement<AutomataBase<Self>, T>
self_t;
/** @name Series related types */ /** @{ */
/// Type of the series set from which the automaton is built.
typedef typename AutomataBase<Self>::series_set_t
series_set_t;
......@@ -413,10 +411,6 @@ namespace vcsn {
typedef semiring_elt_t
weight_t;
/** @} */
/** @name Miscellaneous types */ /** @{ */
/// Type the label kind with which is the automaton is built.
typedef typename AutomataBase<Self>::kind_t
kind_t;
......@@ -433,10 +427,6 @@ namespace vcsn {
typedef typename automaton_traits<T>::geometry_t::coords_t
geometry_coords_t;
/** @} */
/** @name Automata related types */ /** @{ */
/// Type of the label of the automaton implementation.
typedef typename automaton_traits<T>::label_t
label_t;
......@@ -445,10 +435,6 @@ namespace vcsn {
typedef typename automaton_traits<T>::hstate_t
hstate_t;
/** @} */
/** @name States related types */ /** @{ */
/// Type of the states container.
typedef typename automaton_traits<T>::states_t
states_t;
......@@ -475,26 +461,6 @@ namespace vcsn {
/** @} */
/** @name Transitions related types */ /** @{ */
/*
* In Vaucanson, Automata are characterized by their transitions'
* label kind.
* A Transition is a quadruplet composed of a source state,
* a destination state, a label and a weight.
* The label kind of a transition is determined by its automaton type:
* - @c labels_are_letters: Labels are letters, i.e. alphabet elements.
* - @c labels_are_atoms: Labels are letters or the empty word.
* - @c labels_are_words: Labels are monoid elements.
* - @c labels_are_series: There is no 'transitions' in this case
* but 'entries'.
*
* They respect the following hierarchy:
* @c labels_are_letters < @c labels_are_atoms < @c labels_are_words
*
* Any algorithm working on an automaton type works on an inferior type.
*/
typedef typename automaton_traits<T>::htransition_t
htransition_t;
......@@ -512,29 +478,9 @@ namespace vcsn {
typedef typename automaton_traits<T>::rdelta_iterator
rdelta_iterator;
/** @} */
/** @name Entries related types */ /** @{ */
/**
* An Entry is a triplet composed by a source state, a destination
* state and a label. The entry value type is determined by the
* automaton label kind:
* - @c labels_are_letters: Linear Combination of letters, i.e.
* homogeneous first degree polynom.
* - @c labels_are_atoms: Linear Combination of monoid generators.
* - @c labels_are_words: Linear Combination of monoid elements,
* i.e. polynom.
* - @c labels_are_series: Rational Serie.
*
* @todo Really calculate the type according to the kind.
*/
// See entries related methods
typedef series_set_elt_t entry_value_t;
/** @} */
/** @name Miscellaneous functions */ /** @{ */
/// The set of series from which is build the automaton.
const series_set_t& series() const;
......@@ -553,10 +499,6 @@ namespace vcsn {
/// Return true if the automaton is consistent.
bool exists() const;
/** @} */
/** @name States getters */ /** @{ */
/// Accessor to the set of states. (treat as const)
states_t states() const;
......@@ -595,10 +537,6 @@ namespace vcsn {
bool has_state(const hstate_t& state) const;
bool has_state(unsigned state) const;
/** @} */
/** @name Transitions getters */ /** @{ */
/// Accessor to the set of transitions. (treat as const)
transitions_t transitions() const;
......@@ -641,10 +579,6 @@ namespace vcsn {
*/
letter_t letter_of(const htransition_t& e) const;
/** @} */
/** @name States setters */ /** @{ */
/// Set the state to be initial.
void set_initial(const hstate_t& state);
void set_initial(unsigned state);
......@@ -700,10 +634,6 @@ namespace vcsn {
void del_state(const hstate_t& state);
void del_state(unsigned state);
/** @} */
/** @name Transitions setters */ /** @{ */
/// Add a new transition between @c src and @c dst labelled by @c label
htransition_t add_transition(const hstate_t& src, const hstate_t& dst,
const label_t& label);
......@@ -765,15 +695,27 @@ namespace vcsn {
/// Delete the transition @c e.
void del_transition(const htransition_t& e);
/** @} */
/** @name Entries setters */ /** @{ */
/** @} */
/** @name Entries getters */ /** @{ */
/**
* @name Transitions related methods
*
* In Vaucanson, Automata are characterized by their transitions'
* label kind.
* A Transition is a quadruplet composed of a source state,
* a destination state, a label and a weight.
* The label kind of a transition is determined by its automaton type:
* - @c labels_are_letters: Labels are letters, i.e. alphabet elements.
* - @c labels_are_atoms: Labels are letters or the empty word.
* - @c labels_are_words: Labels are monoid elements.
* - @c labels_are_series: There is no 'transitions' in this case
* but 'entries'.
*
* They respect the following hierarchy:
* @c labels_are_letters < @c labels_are_atoms < @c labels_are_words
*
* Any algorithm working on an automaton type works on an inferior type.
*/
/** @} */
/** @{ */
/**
* @brief Add a transition between two states.
......@@ -931,34 +873,6 @@ namespace vcsn {
const weight_t& w,
const label_t& l);
/**
* @brief Add an initial entry to a state.
*
* Add an initial entry of which @c e is the value to @c state.
* - If an initial entry does not exist for @c state, a new
* initial entry is created.
* - If an initial entry already exists for @c state, @c e is
* added to the current entry value.
* - If an initial entry value turns to be null, this initial
* entry is deleted.
*
* @param[in] state The state becoming initial.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_add_initial may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding an initial entry invalidates the
* following iterators:
*
*/
void new_add_initial(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Set values of an initial transition.
*
......@@ -1004,47 +918,6 @@ namespace vcsn {
const weight_t& w,
const label_t& l);
/**
* @brief Set value of an initial entry.
*
* Set the initial entry value to @c e of @c state.
* - If an initial entry does not exist for @c state, a new
* initial entry is created.
* - If an initial entry already exists for @c state, its value
* is replaced by @c e.
* - If an initial entry value turns to be null, this initial
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_set_initial may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding an initial entry invalidates the
* following iterators:
*
*/
void new_set_initial(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Remove initial transitions from a state.
*
* Remove any initial transition from @c state.
*
* @param[in] state The considered state.
*
* @warning Unsetting an initial state invalidates the
* following iterators:
*
*/
void new_unset_initial(const hstate_t& state);
/**
* @brief Add a final transition to a state.
*
......@@ -1063,7 +936,7 @@ namespace vcsn {
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_add_final may change:
* - @c labels_are_letters:
* - @c labels_are_letters:
* -# Adding a letter will behave normally.
* -# Adding an atom is not allowed.
* -# Adding a word is not allowed.
......@@ -1090,34 +963,6 @@ namespace vcsn {
const weight_t& w,
const label_t& l);
/**
* @brief Add a final entry to a state.
*
* Add a final entry of which @c e is the value to @c state.
* - If a final entry does not exist for @c state, a new
* final entry is created.
* - If a final entry already exists for @c state, @c e is
* added to the current entry value.
* - If a final entry value turns to be null, this final
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_add_final may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding a final entry invalidates the
* following iterators:
*
*/
void new_add_final(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Set values of a final transition.
*
......@@ -1162,46 +1007,25 @@ namespace vcsn {
const weight_t& w,
const label_t& l);
/**
* @brief Set values of a final transition.
*
* Set the final entry value to @c e of @c state.
* - If a final entry does not exist for @c state, a new
* final entry is created.
* - If a final entry already exists for @c state, its value
* is replaced by @c e.
* - If a final entry value turns to be null, this final
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_set_final may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Setting a final entry invalidates the
* following iterators:
*
*/
void new_set_final(const hstate_t& state,
const entry_value_t& e);
/** @} */
/**
* @brief Remove final transitions from a state.
* @name Entries related methods
*
* Remove any final transition from @c state.
*
* @param[in] state The considered state.
*
* @warning Unsetting a final state invalidates the
* following iterators:
* An Entry is a triplet composed by a source state, a destination
* state and a label. The entry value type is determined by the
* automaton label kind:
* - @c labels_are_letters: Linear Combination of letters, i.e.
* homogeneous first degree polynom.
* - @c labels_are_atoms: Linear Combination of monoid generators.
* - @c labels_are_words: Linear Combination of monoid elements,
* i.e. polynom.
* - @c labels_are_series: Rational Serie.
*
* @todo Really calculate the type according to the kind.
*/
void new_unset_final(const hstate_t& state);
/** @{ */
/**
* @brief Add a new entry.
......@@ -1316,6 +1140,150 @@ namespace vcsn {
entry_value_t new_get_entry(const hstate_t& src,
const hstate_t& dst) const;
/**
* @brief Add an initial entry to a state.
*
* Add an initial entry of which @c e is the value to @c state.
* - If an initial entry does not exist for @c state, a new
* initial entry is created.
* - If an initial entry already exists for @c state, @c e is
* added to the current entry value.
* - If an initial entry value turns to be null, this initial
* entry is deleted.
*
* @param[in] state The state becoming initial.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_add_initial may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding an initial entry invalidates the
* following iterators:
*
*/
void new_add_initial(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Set value of an initial entry.
*
* Set the initial entry value to @c e of @c state.
* - If an initial entry does not exist for @c state, a new
* initial entry is created.
* - If an initial entry already exists for @c state, its value
* is replaced by @c e.
* - If an initial entry value turns to be null, this initial
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_set_initial may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding an initial entry invalidates the
* following iterators:
*
*/
void new_set_initial(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Add a final entry to a state.
*
* Add a final entry of which @c e is the value to @c state.
* - If a final entry does not exist for @c state, a new
* final entry is created.
* - If a final entry already exists for @c state, @c e is
* added to the current entry value.
* - If a final entry value turns to be null, this final
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_add_final may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Adding a final entry invalidates the
* following iterators:
*
*/
void new_add_final(const hstate_t& state,
const entry_value_t& e);
/**
* @brief Set values of a final transition.
*
* Set the final entry value to @c e of @c state.
* - If a final entry does not exist for @c state, a new
* final entry is created.
* - If a final entry already exists for @c state, its value
* is replaced by @c e.
* - If a final entry value turns to be null, this final
* entry is deleted.
*
* @param[in] state The considered state.
* @param[in] e The entry value.
*
* @note Depending on the automaton label kind, the behaviour of
* @c new_set_final may change:
* - @c labels_are_letters: ...
* - @c labels_are_atoms: ...
* - @c labels_are_words: ...
* - @c labels_are_series: ...
*
* @warning Setting a final entry invalidates the
* following iterators:
*
*/
void new_set_final(const hstate_t& state,
const entry_value_t& e);
/** @} */
/** @name Miscellaneous functions */ /** @{ */
/**
* @brief Remove initial transitions from a state.
*
* Remove any initial transition from @c state.
*
* @param[in] state The considered state.
*
* @warning Unsetting an initial state invalidates the
* following iterators:
*
*/
void new_unset_initial(const hstate_t& state);
/**
* @brief Remove final transitions from a state.
*
* Remove any final transition from @c state.
*
* @param[in] state The considered state.
*
* @warning Unsetting a final state invalidates the
* following iterators:
*
*/
void new_unset_final(const hstate_t& state);
/** @} */
protected:
MetaElement();
MetaElement(const MetaElement& other);
......
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