00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef VCSN_AUTOMATA_CONCEPT_AUTOMATA_BASE_HXX
00018 # define VCSN_AUTOMATA_CONCEPT_AUTOMATA_BASE_HXX
00019
00020 # include <vaucanson/automata/concept/automata_base.hh>
00021 # include <vaucanson/automata/concept/automata_ops.hh>
00022
00023 namespace vcsn {
00024
00025 template <typename Self>
00026 AutomataBase<Self>::AutomataBase()
00027 {}
00028
00029 template <typename Self>
00030 AutomataBase<Self>::AutomataBase(const AutomataBase& other) :
00031 Structure<Self>(other)
00032 {}
00033
00034 template <typename Self>
00035 const typename AutomataBase<Self>::series_set_t&
00036 AutomataBase<Self>::series() const
00037 {
00038 return this->self().series();
00039 }
00040
00041
00043 template <typename Self, typename T>
00044 MetaElement<AutomataBase<Self>, T>::MetaElement()
00045 {}
00046
00048 template <typename Self, typename T>
00049 MetaElement<AutomataBase<Self>, T>::MetaElement(const MetaElement& a):
00050 MetaElement<Structure<Self>, T>::MetaElement(a)
00051 {}
00052
00054 template <typename Self, typename T>
00055 typename MetaElement<AutomataBase<Self>, T>::tag_t&
00056 MetaElement<AutomataBase<Self>, T>::tag()
00057 {
00058 return op_tag(this->structure(), this->value());
00059 }
00060
00062 template <typename Self, typename T>
00063 const typename MetaElement<AutomataBase<Self>, T>::tag_t&
00064 MetaElement<AutomataBase<Self>, T>:: tag() const
00065 {
00066 return op_tag(this->structure(), this->value());
00067 }
00068
00070 template <typename Self, typename T>
00071 typename MetaElement<AutomataBase<Self>, T>::geometry_t&
00072 MetaElement<AutomataBase<Self>, T>::geometry()
00073 {
00074 return op_geometry(this->structure(), this->value());
00075 }
00076
00078 template <typename Self, typename T>
00079 const typename MetaElement<AutomataBase<Self>, T>::geometry_t&
00080 MetaElement<AutomataBase<Self>, T>::geometry() const
00081 {
00082 return op_geometry(this->structure(), this->value());
00083 }
00084
00086 template <typename Self, typename T>
00087 bool
00088 MetaElement<AutomataBase<Self>, T>::exists() const
00089 {
00090 return op_exists(this->structure(), this->value());
00091 }
00092
00094 template <typename Self, typename T>
00095 typename automaton_traits<T>::states_t
00096 MetaElement<AutomataBase<Self>, T>::states() const
00097 {
00098 return op_states(this->structure(), this->value());
00099 }
00100
00102 template <typename Self, typename T>
00103 typename automaton_traits<T>::transitions_t
00104 MetaElement<AutomataBase<Self>, T>::transitions() const
00105 {
00106 return op_transitions(this->structure(), this->value());
00107 }
00108
00110 template <typename Self, typename T>
00111 const typename MetaElement<AutomataBase<Self>, T>::series_set_t&
00112 MetaElement<AutomataBase<Self>, T>::series() const
00113 {
00114 return this->structure().series();
00115 }
00116
00118 template <typename Self, typename T>
00119 typename automaton_traits<T>::initial_support_t
00120 MetaElement<AutomataBase<Self>, T>::initial() const
00121 {
00122 return op_initial(this->structure(), this->value());
00123 }
00124
00126 template <typename Self, typename T>
00127 typename automaton_traits<T>::final_support_t
00128
00129 MetaElement<AutomataBase<Self>, T>::final() const
00130 {
00131 return op_final(this->structure(), this->value());
00132 }
00133
00136 template <typename Self, typename T>
00137 bool
00138 MetaElement<AutomataBase<Self>, T>::is_initial(const typename automaton_traits<T>::hstate_t& state) const
00139 {
00140 return op_is_initial(this->structure(), this->value(), state);
00141 }
00142
00143 template <typename Self, typename T>
00144 bool
00145 MetaElement<AutomataBase<Self>, T>::is_initial(unsigned state) const
00146 {
00147 return op_is_initial(this->structure(), this->value(), state);
00148 }
00149
00151 template <typename Self, typename T>
00152 bool
00153 MetaElement<AutomataBase<Self>, T>::is_final(const typename automaton_traits<T>::hstate_t& state) const
00154 {
00155 return op_is_final(this->structure(), this->value(), state);
00156 }
00157
00158 template <typename Self, typename T>
00159 bool
00160 MetaElement<AutomataBase<Self>, T>::is_final(unsigned state) const
00161 {
00162 return op_is_final(this->structure(), this->value(), state);
00163 }
00164
00166 template <typename Self, typename T>
00167 void
00168 MetaElement<AutomataBase<Self>, T>::set_initial(const typename automaton_traits<T>::hstate_t& state)
00169 {
00170 op_set_initial(this->structure(),
00171 this->value(),
00172 state,
00173 this->structure().series().
00174 identity(SELECT(series_set_elt_value_t)));
00175 }
00176
00177 template <typename Self, typename T>
00178 void
00179 MetaElement<AutomataBase<Self>, T>::set_initial(unsigned state)
00180 {
00181 op_set_initial(this->structure(),
00182 this->value(),
00183 state,
00184 this->structure().series().
00185 identity(SELECT(series_set_elt_value_t)));
00186 }
00187
00189 template <typename Self, typename T>
00190 void
00191 MetaElement<AutomataBase<Self>, T>::
00192 set_initial(const typename automaton_traits<T>::hstate_t& state, const series_set_elt_t& s)
00193 {
00194 op_set_initial(this->structure(), this->value(), state, s);
00195 }
00196
00197 template <typename Self, typename T>
00198 void
00199 MetaElement<AutomataBase<Self>, T>::
00200 set_initial(unsigned state, const series_set_elt_t& s)
00201 {
00202 op_set_initial(this->structure(), this->value(), state, s);
00203 }
00204
00206 template <typename Self, typename T>
00207 void
00208 MetaElement<AutomataBase<Self>, T>::set_final(const typename automaton_traits<T>::hstate_t& state)
00209 {
00210 op_set_final(this->structure(),
00211 this->value(),
00212 state,
00213 this->structure().series().
00214 identity(SELECT(series_set_elt_value_t)));
00215 }
00216
00217 template <typename Self, typename T>
00218 void
00219 MetaElement<AutomataBase<Self>, T>::set_final(unsigned state)
00220 {
00221 op_set_final(this->structure(),
00222 this->value(),
00223 state,
00224 this->structure().series().
00225 identity(SELECT(series_set_elt_value_t)));
00226 }
00227
00229 template <typename Self, typename T>
00230 void
00231 MetaElement<AutomataBase<Self>, T>::
00232 set_final(const typename automaton_traits<T>::hstate_t& state, const series_set_elt_t& s)
00233 {
00234 op_set_final(this->structure(), this->value(), state, s);
00235 }
00236
00237 template <typename Self, typename T>
00238 void
00239 MetaElement<AutomataBase<Self>, T>::
00240 set_final(unsigned state, const series_set_elt_t& s)
00241 {
00242 op_set_final(this->structure(), this->value(), state, s);
00243 }
00244
00246 template <typename Self, typename T>
00247 void
00248 MetaElement<AutomataBase<Self>, T>::unset_initial(const typename automaton_traits<T>::hstate_t& state)
00249 {
00250 op_set_initial(this->structure(),
00251 this->value(),
00252 state,
00253 algebra::zero_as<series_set_elt_value_t>::
00254 of(this->structure().series()));
00255 }
00256
00257 template <typename Self, typename T>
00258 void
00259 MetaElement<AutomataBase<Self>, T>::unset_initial(unsigned state)
00260 {
00261 op_set_initial(this->structure(),
00262 this->value(),
00263 state,
00264 algebra::zero_as<series_set_elt_value_t>::
00265 of(this->structure().series()));
00266 }
00267
00269 template <typename Self, typename T>
00270 void
00271 MetaElement<AutomataBase<Self>, T>::unset_final(const typename automaton_traits<T>::hstate_t& state)
00272 {
00273 op_set_final(this->structure(),
00274 this->value(),
00275 state,
00276 algebra::zero_as<series_set_elt_value_t>::
00277 of(this->structure().series()));
00278 }
00279
00280 template <typename Self, typename T>
00281 void
00282 MetaElement<AutomataBase<Self>, T>::unset_final(unsigned state)
00283 {
00284 op_set_final(this->structure(),
00285 this->value(),
00286 state,
00287 algebra::zero_as<series_set_elt_value_t>::
00288 of(this->structure().series()));
00289 }
00290
00292 template <typename Self, typename T>
00293 void
00294 MetaElement<AutomataBase<Self>, T>::clear_initial()
00295 {
00296 return op_clear_initial(this->structure(), this->value());
00297 }
00298
00300 template <typename Self, typename T>
00301 void
00302 MetaElement<AutomataBase<Self>, T>::clear_final()
00303 {
00304 return op_clear_final(this->structure(), this->value());
00305 }
00306
00308 template <typename Self, typename T>
00309 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_t
00310 MetaElement<AutomataBase<Self>, T>::get_initial(const typename automaton_traits<T>::hstate_t& state) const
00311 {
00312 return op_get_initial(this->structure(), this->value(), state);
00313 }
00314
00315 template <typename Self, typename T>
00316 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_t
00317 MetaElement<AutomataBase<Self>, T>::get_initial(unsigned state) const
00318 {
00319 return op_get_initial(this->structure(), this->value(), state);
00320 }
00321
00323 template <typename Self, typename T>
00324 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_t
00325 MetaElement<AutomataBase<Self>, T>::get_final(const typename automaton_traits<T>::hstate_t& state) const
00326 {
00327 return op_get_final(this->structure(), this->value(), state);
00328 }
00329
00330 template <typename Self, typename T>
00331 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_t
00332 MetaElement<AutomataBase<Self>, T>::get_final(unsigned state) const
00333 {
00334 return op_get_final(this->structure(), this->value(), state);
00335 }
00336
00338 template <typename Self, typename T>
00339 typename automaton_traits<T>::hstate_t
00340 MetaElement<AutomataBase<Self>, T>::add_state()
00341 {
00342 return op_add_state(this->structure(), this->value());
00343 }
00344
00346 template <typename Self, typename T>
00347 typename automaton_traits<T>::hstate_t
00348 MetaElement<AutomataBase<Self>, T>::get_state(unsigned state) const
00349 {
00350 return op_get_state(this->structure(), this->value(), state);
00351 }
00352
00355 template <typename Self, typename T>
00356 typename automaton_traits<T>::hstate_t
00357 MetaElement<AutomataBase<Self>, T>::choose_state() const
00358 {
00359 return op_choose_state(this->structure(), this->value());
00360 }
00361
00363 template <typename Self, typename T>
00364 typename automaton_traits<T>::htransition_t
00365 MetaElement<AutomataBase<Self>, T>::add_transition(const typename automaton_traits<T>::hstate_t& src,
00366 const typename automaton_traits<T>::hstate_t& dst,
00367 const label_t& label)
00368 {
00369 return op_add_transition(this->structure(), this->value(),
00370 src, dst, label);
00371 }
00372
00373 template <typename Self, typename T>
00374 typename automaton_traits<T>::htransition_t
00375 MetaElement<AutomataBase<Self>, T>::add_transition(unsigned src,
00376 unsigned dst,
00377 const label_t& label)
00378 {
00379 return op_add_transition(this->structure(), this->value(),
00380 src, dst, label);
00381 }
00382
00384 template <typename Self, typename T>
00385 typename automaton_traits<T>::htransition_t
00386 MetaElement<AutomataBase<Self>, T>::
00387 add_weighted_transition(const typename automaton_traits<T>::hstate_t& src,
00388 const typename automaton_traits<T>::hstate_t& dst,
00389 const semiring_elt_t& w,
00390 const monoid_elt_value_t& m)
00391 {
00392 return op_add_weighted_transition(this->structure(), this->value(),
00393 src, dst, w, m);
00394 }
00395
00396 template <typename Self, typename T>
00397 typename automaton_traits<T>::htransition_t
00398 MetaElement<AutomataBase<Self>, T>::
00399 add_weighted_transition(unsigned src,
00400 unsigned dst,
00401 const semiring_elt_t& w,
00402 const monoid_elt_value_t& m)
00403 {
00404 return op_add_weighted_transition(this->structure(), this->value(),
00405 src, dst, w, m);
00406 }
00407
00411 template <typename Self, typename T>
00412 typename automaton_traits<T>::htransition_t
00413 MetaElement<AutomataBase<Self>, T>::add_series_transition(const typename automaton_traits<T>::hstate_t& src,
00414 const typename automaton_traits<T>::hstate_t& dst,
00415 const series_set_elt_t& e)
00416 {
00417 return op_add_series_transition(this->structure(), this->value(),
00418 src, dst, e);
00419 }
00420
00421 template <typename Self, typename T>
00422 typename automaton_traits<T>::htransition_t
00423 MetaElement<AutomataBase<Self>, T>::add_series_transition(unsigned src,
00424 unsigned dst,
00425 const series_set_elt_t& e)
00426 {
00427 return op_add_series_transition(this->structure(), this->value(),
00428 src, dst, e);
00429 }
00430
00432 template <typename Self, typename T>
00433 typename automaton_traits<T>::htransition_t
00434 MetaElement<AutomataBase<Self>, T>::add_spontaneous(const typename automaton_traits<T>::hstate_t& src,
00435 const typename automaton_traits<T>::hstate_t& dst)
00436 {
00437 semiring_elt_t w(this->structure().series().semiring());
00438 w = algebra::identity_as<semiring_elt_value_t>
00439 ::of(this->structure().series().semiring());
00440 return op_add_spontaneous(this->structure(), this->value(), src, dst, w);
00441 }
00442
00443 template <typename Self, typename T>
00444 typename automaton_traits<T>::htransition_t
00445 MetaElement<AutomataBase<Self>, T>::add_spontaneous(unsigned src,
00446 unsigned dst)
00447 {
00448 semiring_elt_t w(this->structure().series().semiring());
00449 w = algebra::identity_as<semiring_elt_value_t>
00450 ::of(this->structure().series().semiring());
00451 return op_add_spontaneous(this->structure(), this->value(), src, dst, w);
00452 }
00453
00454 template <typename Self, typename T>
00455 typename automaton_traits<T>::htransition_t
00456 MetaElement<AutomataBase<Self>, T>::add_spontaneous(const typename automaton_traits<T>::hstate_t& src,
00457 const typename automaton_traits<T>::hstate_t& dst,
00458 const semiring_elt_t& w)
00459 {
00460 return op_add_spontaneous(this->structure(), this->value(), src, dst, w);
00461 }
00462
00463 template <typename Self, typename T>
00464 typename automaton_traits<T>::htransition_t
00465 MetaElement<AutomataBase<Self>, T>::add_spontaneous(unsigned src,
00466 unsigned dst,
00467 const semiring_elt_t& w)
00468 {
00469 return op_add_spontaneous(this->structure(), this->value(), src, dst, w);
00470 }
00471
00473 template <typename Self, typename T>
00474 typename automaton_traits<T>::htransition_t
00475 MetaElement<AutomataBase<Self>, T>::add_letter_transition(const typename automaton_traits<T>::hstate_t& src,
00476 const typename automaton_traits<T>::hstate_t& dst,
00477 const letter_t& l)
00478 {
00479 return op_add_letter_transition(this->structure(), this->value(),
00480 src, dst, l);
00481 }
00482
00483 template <typename Self, typename T>
00484 typename automaton_traits<T>::htransition_t
00485 MetaElement<AutomataBase<Self>, T>::add_letter_transition(unsigned src,
00486 unsigned dst,
00487 const letter_t& l)
00488 {
00489 return op_add_letter_transition(this->structure(), this->value(),
00490 src, dst, l);
00491 }
00492
00495 template <typename Self, typename T>
00496 typename automaton_traits<T>::htransition_t
00497 MetaElement<AutomataBase<Self>, T>::add_letter_transition(const typename automaton_traits<T>::hstate_t& src,
00498 const typename automaton_traits<T>::hstate_t& dst,
00499 const std::string& l)
00500 {
00501 return op_add_letter_transition(this->structure(), this->value(),
00502 src, dst, algebra::letter_traits<letter_t>::
00503 literal_to_letter(l));
00504 }
00505
00506 template <typename Self, typename T>
00507 typename automaton_traits<T>::htransition_t
00508 MetaElement<AutomataBase<Self>, T>::add_letter_transition(unsigned src,
00509 unsigned dst,
00510 const std::string& l)
00511 {
00512 return op_add_letter_transition(this->structure(), this->value(),
00513 src, dst, algebra::letter_traits<letter_t>::
00514 literal_to_letter(l));
00515 }
00516
00518 template <typename Self, typename T>
00519 void
00520 MetaElement<AutomataBase<Self>, T>::update(const typename automaton_traits<T>::htransition_t& e, const label_t& l)
00521 {
00522 op_update(this->structure(), this->value(), e, l);
00523 }
00524
00526 template <typename Self, typename T>
00527 void
00528 MetaElement<AutomataBase<Self>, T>::del_state(const typename automaton_traits<T>::hstate_t& s)
00529 {
00530 return op_del_state(this->structure(), this->value(), s);
00531 }
00532
00533 template <typename Self, typename T>
00534 void
00535 MetaElement<AutomataBase<Self>, T>::del_state(unsigned state)
00536 {
00537 return op_del_state(this->structure(), this->value(), state);
00538 }
00539
00541 template <typename Self, typename T>
00542 void
00543 MetaElement<AutomataBase<Self>, T>::del_transition(const typename automaton_traits<T>::htransition_t& e)
00544 {
00545 return op_del_transition(this->structure(), this->value(), e);
00546 }
00547
00549 template <typename Self, typename T>
00550 bool
00551 MetaElement<AutomataBase<Self>, T>::has_state(const typename automaton_traits<T>::hstate_t& s) const
00552 {
00553 return op_has_state(this->structure(), this->value(), s);
00554 }
00555
00556 template <typename Self, typename T>
00557 bool
00558 MetaElement<AutomataBase<Self>, T>::has_state(unsigned state) const
00559 {
00560 return op_has_state(this->structure(), this->value(), state);
00561 }
00562
00564 template <typename Self, typename T>
00565 bool
00566 MetaElement<AutomataBase<Self>, T>::has_transition(const typename automaton_traits<T>::htransition_t& e) const
00567 {
00568 return op_has_transition(this->structure(), this->value(), e);
00569 }
00570
00572 template <typename Self, typename T>
00573 typename automaton_traits<T>::hstate_t
00574 MetaElement<AutomataBase<Self>, T>::src_of(const typename automaton_traits<T>::htransition_t& e) const
00575 {
00576 return op_src_of(this->structure(), this->value(), e);
00577 }
00578
00580 template <typename Self, typename T>
00581 typename automaton_traits<T>::hstate_t
00582 MetaElement<AutomataBase<Self>, T>::dst_of(const typename automaton_traits<T>::htransition_t& e) const
00583 {
00584 return op_dst_of(this->structure(), this->value(), e);
00585 }
00586
00588 template <typename Self, typename T>
00589 typename automaton_traits<T>::label_t
00590 MetaElement<AutomataBase<Self>, T>::label_of(const typename automaton_traits<T>::htransition_t& e) const
00591 {
00592 return op_label_of(this->structure(), this->value(), e);
00593 }
00594
00596 template <typename Self, typename T>
00597 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_t
00598 MetaElement<AutomataBase<Self>, T>::series_of(const typename automaton_traits<T>::htransition_t& e) const
00599 {
00600 return op_series_of(this->structure(), this->value(), e);
00601 }
00602
00604 template <typename Self, typename T>
00605 typename MetaElement<AutomataBase<Self>, T>::series_set_elt_value_t
00606 MetaElement<AutomataBase<Self>, T>::series_value_of(const typename automaton_traits<T>::htransition_t& e) const
00607 {
00608 return op_series_value_of(this->structure(), this->value(), e);
00609 }
00610
00612 template <typename Self, typename T>
00613 bool
00614 MetaElement<AutomataBase<Self>, T>::is_spontaneous(const typename automaton_traits<T>::htransition_t& e) const
00615 {
00616 return op_is_spontaneous(this->structure(), this->value(), e);
00617 }
00618
00620 template <typename Self, typename T>
00621 typename MetaElement<AutomataBase<Self>, T>::monoid_elt_t
00622 MetaElement<AutomataBase<Self>, T>::word_of(const typename automaton_traits<T>::htransition_t& e) const
00623 {
00624 return op_word_of(this->structure(), this->value(), e);
00625 }
00626
00628 template <typename Self, typename T>
00629 typename MetaElement<AutomataBase<Self>, T>::semiring_elt_t
00630 MetaElement<AutomataBase<Self>, T>::weight_of(const typename automaton_traits<T>::htransition_t& e) const
00631 {
00632 return op_weight_of(this->structure(), this->value(), e);
00633 }
00634
00636 template <typename Self, typename T>
00637 typename MetaElement<AutomataBase<Self>, T>::monoid_elt_value_t
00638 MetaElement<AutomataBase<Self>, T>::word_value_of(const typename automaton_traits<T>::htransition_t& e) const
00639 {
00640 return op_word_value_of(this->structure(), this->value(), e);
00641 }
00642
00646 template <typename Self, typename T>
00647 typename MetaElement<AutomataBase<Self>, T>::letter_t
00648 MetaElement<AutomataBase<Self>, T>::letter_of(const typename automaton_traits<T>::htransition_t& e) const
00649 {
00650 return op_letter_of(this->structure(), this->value(), e);
00651 }
00652
00653
00654
00655
00656
00657 template <typename Self, typename T>
00658 template <typename OutputIterator, typename Kind>
00659 void
00660 MetaElement<AutomataBase<Self>, T>::delta(OutputIterator res,
00661 const typename automaton_traits<T>::hstate_t& src,
00662 delta_kind::kind<Kind> k) const
00663 {
00664 op_delta(this->structure(), this->value(), res, src, k);
00665 }
00666
00667 template <typename Self, typename T>
00668 template <typename OutputIterator, typename Kind>
00669 void
00670 MetaElement<AutomataBase<Self>, T>::delta(OutputIterator res,
00671 unsigned src,
00672 delta_kind::kind<Kind> k) const
00673 {
00674 op_delta(this->structure(), this->value(), res, src, k);
00675 }
00676
00677 template <typename Self, typename T>
00678 template <typename OutputIterator, typename L, typename Kind>
00679 void
00680 MetaElement<AutomataBase<Self>, T>::delta(OutputIterator res,
00681 const typename automaton_traits<T>::hstate_t& src,
00682 const L& query,
00683 delta_kind::kind<Kind> k) const
00684 {
00685 op_delta(this->structure(), this->value(), res, src, query, k);
00686 }
00687
00688 template <typename Self, typename T>
00689 template <typename OutputIterator, typename L, typename Kind>
00690 void
00691 MetaElement<AutomataBase<Self>, T>::delta(OutputIterator res,
00692 unsigned src,
00693 const L& query,
00694 delta_kind::kind<Kind> k) const
00695 {
00696 op_delta(this->structure(), this->value(), res, src, query, k);
00697 }
00698
00699 template <typename Self, typename T>
00700 template <typename OutputIterator, typename L, typename Kind>
00701 void
00702 MetaElement<AutomataBase<Self>, T>::letter_delta(OutputIterator res,
00703 const typename automaton_traits<T>::hstate_t& src,
00704 const L& letter,
00705 delta_kind::kind<Kind> k) const
00706 {
00707 op_letter_delta(this->structure(), this->value(), res, src, letter, k);
00708 }
00709
00710 template <typename Self, typename T>
00711 template <typename OutputIterator, typename L, typename Kind>
00712 void
00713 MetaElement<AutomataBase<Self>, T>::letter_delta(OutputIterator res,
00714 unsigned src,
00715 const L& letter,
00716 delta_kind::kind<Kind> k) const
00717 {
00718 op_letter_delta(this->structure(), this->value(), res, src, letter, k);
00719 }
00720
00721 template <typename Self, typename T>
00722 template <typename OutputIterator, typename Kind>
00723 void
00724 MetaElement<AutomataBase<Self>, T>
00725 ::spontaneous_delta(OutputIterator res,
00726 const typename automaton_traits<T>::hstate_t& src,
00727 delta_kind::kind<Kind> k) const
00728 {
00729 return op_spontaneous_delta(this->structure(), this->value(), res, src, k);
00730 }
00731
00732 template <typename Self, typename T>
00733 template <typename OutputIterator, typename Kind>
00734 void
00735 MetaElement<AutomataBase<Self>, T>
00736 ::spontaneous_delta(OutputIterator res,
00737 unsigned src,
00738 delta_kind::kind<Kind> k) const
00739 {
00740 return op_spontaneous_delta(this->structure(), this->value(), res, src, k);
00741 }
00742
00743
00744
00745
00746
00747 template <typename Self, typename T>
00748 template <typename Container, typename Kind>
00749 void
00750 MetaElement<AutomataBase<Self>, T>::deltac(Container& res, const typename automaton_traits<T>::hstate_t& src,
00751 delta_kind::kind<Kind> k) const
00752 {
00753 op_deltac(this->structure(), this->value(), res, src, k);
00754 }
00755
00756 template <typename Self, typename T>
00757 template <typename Container, typename Kind>
00758 void
00759 MetaElement<AutomataBase<Self>, T>::deltac(Container& res, unsigned src,
00760 delta_kind::kind<Kind> k) const
00761 {
00762 op_deltac(this->structure(), this->value(), res, src, k);
00763 }
00764
00765 template <typename Self, typename T>
00766 template <typename Container, typename L, typename Kind>
00767 void
00768 MetaElement<AutomataBase<Self>, T>::deltac(Container& res,
00769 const typename automaton_traits<T>::hstate_t& src,
00770 const L& query,
00771 delta_kind::kind<Kind> k) const
00772 {
00773 op_deltac(this->structure(), this->value(), res, src, query, k);
00774 }
00775
00776 template <typename Self, typename T>
00777 template <typename Container, typename L, typename Kind>
00778 void
00779 MetaElement<AutomataBase<Self>, T>::deltac(Container& res,
00780 unsigned src,
00781 const L& query,
00782 delta_kind::kind<Kind> k) const
00783 {
00784 op_deltac(this->structure(), this->value(), res, src, query, k);
00785 }
00786
00787 template <typename Self, typename T>
00788 template <typename Container, typename L, typename Kind>
00789 void
00790 MetaElement<AutomataBase<Self>, T>::letter_deltac(Container& res,
00791 const typename automaton_traits<T>::hstate_t& src,
00792 const L& letter,
00793 delta_kind::kind<Kind> k) const
00794 {
00795 op_letter_deltac(this->structure(), this->value(), res, src, letter, k);
00796 }
00797
00798 template <typename Self, typename T>
00799 template <typename Container, typename L, typename Kind>
00800 void
00801 MetaElement<AutomataBase<Self>, T>::letter_deltac(Container& res,
00802 unsigned src,
00803 const L& letter,
00804 delta_kind::kind<Kind> k) const
00805 {
00806 op_letter_deltac(this->structure(), this->value(), res, src, letter, k);
00807 }
00808
00809 template <typename Self, typename T>
00810 template <typename Container, typename Kind>
00811 void
00812 MetaElement<AutomataBase<Self>, T>
00813 ::spontaneous_deltac(Container& res,
00814 const typename automaton_traits<T>::hstate_t& src,
00815 delta_kind::kind<Kind> k) const
00816 {
00817 op_spontaneous_deltac(this->structure(), this->value(), res, src, k);
00818 }
00819
00820 template <typename Self, typename T>
00821 template <typename Container, typename Kind>
00822 void
00823 MetaElement<AutomataBase<Self>, T>
00824 ::spontaneous_deltac(Container& res,
00825 unsigned src,
00826 delta_kind::kind<Kind> k) const
00827 {
00828 op_spontaneous_deltac(this->structure(), this->value(), res, src, k);
00829 }
00830
00831
00832
00833
00834
00835 template <typename Self, typename T>
00836 template <typename Functor, typename Kind>
00837 void
00838 MetaElement<AutomataBase<Self>, T>::deltaf(Functor& fun, const typename automaton_traits<T>::hstate_t& src,
00839 delta_kind::kind<Kind> k) const
00840 {
00841 op_deltaf(this->structure(), this->value(), fun, src, k);
00842 }
00843
00844 template <typename Self, typename T>
00845 template <typename Functor, typename Kind>
00846 void
00847 MetaElement<AutomataBase<Self>, T>::deltaf(Functor& fun, unsigned src,
00848 delta_kind::kind<Kind> k) const
00849 {
00850 op_deltaf(this->structure(), this->value(), fun, src, k);
00851 }
00852
00853 template <typename Self, typename T>
00854 template <typename Functor, typename L, typename Kind>
00855 void
00856 MetaElement<AutomataBase<Self>, T>::deltaf(Functor& fun,
00857 const typename automaton_traits<T>::hstate_t& src,
00858 const L& query,
00859 delta_kind::kind<Kind> k) const
00860 {
00861 op_deltaf(this->structure(), this->value(), fun, src, query, k);
00862 }
00863
00864 template <typename Self, typename T>
00865 template <typename Functor, typename L, typename Kind>
00866 void
00867 MetaElement<AutomataBase<Self>, T>::deltaf(Functor& fun,
00868 unsigned src,
00869 const L& query,
00870 delta_kind::kind<Kind> k) const
00871 {
00872 op_deltaf(this->structure(), this->value(), fun, src, query, k);
00873 }
00874
00875 template <typename Self, typename T>
00876 template <typename Functor, typename L, typename Kind>
00877 void
00878 MetaElement<AutomataBase<Self>, T>::letter_deltaf(Functor& fun,
00879 const typename automaton_traits<T>::hstate_t& src,
00880 const L& letter,
00881 delta_kind::kind<Kind> k) const
00882 {
00883 op_letter_deltaf(this->structure(), this->value(), fun, src, letter, k);
00884 }
00885
00886 template <typename Self, typename T>
00887 template <typename Functor, typename L, typename Kind>
00888 void
00889 MetaElement<AutomataBase<Self>, T>::letter_deltaf(Functor& fun,
00890 unsigned src,
00891 const L& letter,
00892 delta_kind::kind<Kind> k) const
00893 {
00894 op_letter_deltaf(this->structure(), this->value(), fun, src, letter, k);
00895 }
00896
00897 template <typename Self, typename T>
00898 template <typename Functor, typename Kind>
00899 void
00900 MetaElement<AutomataBase<Self>, T>
00901 ::spontaneous_deltaf(Functor& fun,
00902 const typename automaton_traits<T>::hstate_t& src,
00903 delta_kind::kind<Kind> k) const
00904 {
00905 op_spontaneous_deltaf(this->structure(), this->value(), fun, src, k);
00906 }
00907
00908 template <typename Self, typename T>
00909 template <typename Functor, typename Kind>
00910 void
00911 MetaElement<AutomataBase<Self>, T>
00912 ::spontaneous_deltaf(Functor& fun,
00913 unsigned src,
00914 delta_kind::kind<Kind> k) const
00915 {
00916 op_spontaneous_deltaf(this->structure(), this->value(), fun, src, k);
00917 }
00918
00919
00920
00921
00922
00923 template <typename Self, typename T>
00924 template <typename OutputIterator, typename Kind>
00925 void
00926 MetaElement<AutomataBase<Self>, T>::rdelta(OutputIterator res,
00927 const typename automaton_traits<T>::hstate_t& src,
00928 delta_kind::kind<Kind> k) const
00929 {
00930 op_rdelta(this->structure(), this->value(), res, src, k);
00931 }
00932
00933 template <typename Self, typename T>
00934 template <typename OutputIterator, typename Kind>
00935 void
00936 MetaElement<AutomataBase<Self>, T>::rdelta(OutputIterator res,
00937 unsigned src,
00938 delta_kind::kind<Kind> k) const
00939 {
00940 op_rdelta(this->structure(), this->value(), res, src, k);
00941 }
00942
00943 template <typename Self, typename T>
00944 template <typename OutputIterator, typename L, typename Kind>
00945 void
00946 MetaElement<AutomataBase<Self>, T>::rdelta(OutputIterator res,
00947 const typename automaton_traits<T>::hstate_t& src,
00948 const L& query,
00949 delta_kind::kind<Kind> k) const
00950 {
00951 op_rdelta(this->structure(), this->value(), res, src, query, k);
00952 }
00953
00954 template <typename Self, typename T>
00955 template <typename OutputIterator, typename L, typename Kind>
00956 void
00957 MetaElement<AutomataBase<Self>, T>::rdelta(OutputIterator res,
00958 unsigned src,
00959 const L& query,
00960 delta_kind::kind<Kind> k) const
00961 {
00962 op_rdelta(this->structure(), this->value(), res, src, query, k);
00963 }
00964
00965 template <typename Self, typename T>
00966 template <typename OutputIterator, typename L, typename Kind>
00967 void
00968 MetaElement<AutomataBase<Self>, T>::letter_rdelta(OutputIterator res,
00969 const typename automaton_traits<T>::hstate_t& src,
00970 const L& letter,
00971 delta_kind::kind<Kind> k) const
00972 {
00973 op_letter_rdelta(this->structure(), this->value(), res, src, letter, k);
00974 }
00975
00976 template <typename Self, typename T>
00977 template <typename OutputIterator, typename L, typename Kind>
00978 void
00979 MetaElement<AutomataBase<Self>, T>::letter_rdelta(OutputIterator res,
00980 unsigned src,
00981 const L& letter,
00982 delta_kind::kind<Kind> k) const
00983 {
00984 op_letter_rdelta(this->structure(), this->value(), res, src, letter, k);
00985 }
00986
00987 template <typename Self, typename T>
00988 template <typename OutputIterator, typename Kind>
00989 void
00990 MetaElement<AutomataBase<Self>, T>
00991 ::spontaneous_rdelta(OutputIterator res,
00992 const typename automaton_traits<T>::hstate_t& src,
00993 delta_kind::kind<Kind> k) const
00994 {
00995 return op_spontaneous_rdelta(this->structure(), this->value(), res, src, k);
00996 }
00997
00998 template <typename Self, typename T>
00999 template <typename OutputIterator, typename Kind>
01000 void
01001 MetaElement<AutomataBase<Self>, T>
01002 ::spontaneous_rdelta(OutputIterator res,
01003 unsigned src,
01004 delta_kind::kind<Kind> k) const
01005 {
01006 return op_spontaneous_rdelta(this->structure(), this->value(), res, src, k);
01007 }
01008
01009
01010
01011
01012
01013 template <typename Self, typename T>
01014 template <typename Container, typename Kind>
01015 void
01016 MetaElement<AutomataBase<Self>, T>::rdeltac(Container& res, const typename automaton_traits<T>::hstate_t& src,
01017 delta_kind::kind<Kind> k) const
01018 {
01019 op_rdeltac(this->structure(), this->value(), res, src, k);
01020 }
01021
01022 template <typename Self, typename T>
01023 template <typename Container, typename Kind>
01024 void
01025 MetaElement<AutomataBase<Self>, T>::rdeltac(Container& res, unsigned src,
01026 delta_kind::kind<Kind> k) const
01027 {
01028 op_rdeltac(this->structure(), this->value(), res, src, k);
01029 }
01030
01031 template <typename Self, typename T>
01032 template <typename Container, typename L, typename Kind>
01033 void
01034 MetaElement<AutomataBase<Self>, T>::rdeltac(Container& res,
01035 const typename automaton_traits<T>::hstate_t& src,
01036 const L& query,
01037 delta_kind::kind<Kind> k) const
01038 {
01039 op_rdeltac(this->structure(), this->value(), res, src, query, k);
01040 }
01041
01042 template <typename Self, typename T>
01043 template <typename Container, typename L, typename Kind>
01044 void
01045 MetaElement<AutomataBase<Self>, T>::rdeltac(Container& res,
01046 unsigned src,
01047 const L& query,
01048 delta_kind::kind<Kind> k) const
01049 {
01050 op_rdeltac(this->structure(), this->value(), res, src, query, k);
01051 }
01052
01053 template <typename Self, typename T>
01054 template <typename Container, typename L, typename Kind>
01055 void
01056 MetaElement<AutomataBase<Self>, T>::letter_rdeltac(Container& res,
01057 const typename automaton_traits<T>::hstate_t& src,
01058 const L& letter,
01059 delta_kind::kind<Kind> k) const
01060 {
01061 op_letter_rdeltac(this->structure(), this->value(), res, src, letter, k);
01062 }
01063
01064 template <typename Self, typename T>
01065 template <typename Container, typename L, typename Kind>
01066 void
01067 MetaElement<AutomataBase<Self>, T>::letter_rdeltac(Container& res,
01068 unsigned src,
01069 const L& letter,
01070 delta_kind::kind<Kind> k) const
01071 {
01072 op_letter_rdeltac(this->structure(), this->value(), res, src, letter, k);
01073 }
01074
01075 template <typename Self, typename T>
01076 template <typename Container, typename Kind>
01077 void
01078 MetaElement<AutomataBase<Self>, T>
01079 ::spontaneous_rdeltac(Container& res,
01080 const typename automaton_traits<T>::hstate_t& src,
01081 delta_kind::kind<Kind> k) const
01082 {
01083 op_spontaneous_rdeltac(this->structure(), this->value(), res, src, k);
01084 }
01085
01086 template <typename Self, typename T>
01087 template <typename Container, typename Kind>
01088 void
01089 MetaElement<AutomataBase<Self>, T>
01090 ::spontaneous_rdeltac(Container& res,
01091 unsigned src,
01092 delta_kind::kind<Kind> k) const
01093 {
01094 op_spontaneous_rdeltac(this->structure(), this->value(), res, src, k);
01095 }
01096
01097
01098
01099
01100
01101 template <typename Self, typename T>
01102 template <typename Functor, typename Kind>
01103 void
01104 MetaElement<AutomataBase<Self>, T>::rdeltaf(Functor& fun, const typename automaton_traits<T>::hstate_t& src,
01105 delta_kind::kind<Kind> k) const
01106 {
01107 op_rdeltaf(this->structure(), this->value(), fun, src, k);
01108 }
01109
01110 template <typename Self, typename T>
01111 template <typename Functor, typename Kind>
01112 void
01113 MetaElement<AutomataBase<Self>, T>::rdeltaf(Functor& fun, unsigned src,
01114 delta_kind::kind<Kind> k) const
01115 {
01116 op_rdeltaf(this->structure(), this->value(), fun, src, k);
01117 }
01118
01119 template <typename Self, typename T>
01120 template <typename Functor, typename L, typename Kind>
01121 void
01122 MetaElement<AutomataBase<Self>, T>::rdeltaf(Functor& fun,
01123 const typename automaton_traits<T>::hstate_t& src,
01124 const L& query,
01125 delta_kind::kind<Kind> k) const
01126 {
01127 op_rdeltaf(this->structure(), this->value(), fun, src, query, k);
01128 }
01129
01130 template <typename Self, typename T>
01131 template <typename Functor, typename L, typename Kind>
01132 void
01133 MetaElement<AutomataBase<Self>, T>::rdeltaf(Functor& fun,
01134 unsigned src,
01135 const L& query,
01136 delta_kind::kind<Kind> k) const
01137 {
01138 op_rdeltaf(this->structure(), this->value(), fun, src, query, k);
01139 }
01140
01141 template <typename Self, typename T>
01142 template <typename Functor, typename L, typename Kind>
01143 void
01144 MetaElement<AutomataBase<Self>, T>::letter_rdeltaf(Functor& fun,
01145 const typename automaton_traits<T>::hstate_t& src,
01146 const L& letter,
01147 delta_kind::kind<Kind> k) const
01148 {
01149 op_letter_rdeltaf(this->structure(), this->value(), fun, src, letter, k);
01150 }
01151
01152 template <typename Self, typename T>
01153 template <typename Functor, typename L, typename Kind>
01154 void
01155 MetaElement<AutomataBase<Self>, T>::letter_rdeltaf(Functor& fun,
01156 unsigned src,
01157 const L& letter,
01158 delta_kind::kind<Kind> k) const
01159 {
01160 op_letter_rdeltaf(this->structure(), this->value(), fun, src, letter, k);
01161 }
01162
01163 template <typename Self, typename T>
01164 template <typename Functor, typename Kind>
01165 void
01166 MetaElement<AutomataBase<Self>, T>
01167 ::spontaneous_rdeltaf(Functor& fun,
01168 const typename automaton_traits<T>::hstate_t& src,
01169 delta_kind::kind<Kind> k) const
01170 {
01171 op_spontaneous_rdeltaf(this->structure(), this->value(), fun, src, k);
01172 }
01173
01174 template <typename Self, typename T>
01175 template <typename Functor, typename Kind>
01176 void
01177 MetaElement<AutomataBase<Self>, T>
01178 ::spontaneous_rdeltaf(Functor& fun,
01179 unsigned src,
01180 delta_kind::kind<Kind> k) const
01181 {
01182 op_spontaneous_rdeltaf(this->structure(), this->value(), fun, src, k);
01183 }
01184
01185
01186 template<typename S, typename St, typename T>
01187 St& op_rout(const AutomataBase<S>& s, St& st, const T& v)
01188 {
01189 Element<S, T> r(s.self(), v);
01190 st << "{ "
01191 << r.states().size() << " states, "
01192 << r.transitions().size() << " transitions, "
01193 << "#I = " << r.initial().size() << ", "
01194 << "#T = " << r.final().size()
01195 << " }";
01196 return st;
01197 }
01198
01199
01200 }
01201
01202 #endif // ! VCSN_AUTOMATA_CONCEPT_AUTOMATA_BASE_HXX