17template<
class SymbolType,
class StateType >
27template<
class SymbolType,
class StateType >
46 res.addInputSymbol(symbol);
47 symbols.push_back(symbol);
61 parseTransition(input,
res, symbols);
71template<
class SymbolType,
class StateType >
80 if(initial)
res.addInitialState(from);
81 if(
final)
res.addFinalState(from);
87 if(iter == symbols.
end())
95 res.addTransition(from, *iter, to);
110template<
class SymbolType,
class StateType >
115template<
class SymbolType,
class StateType >
118 for(
const auto& symbol :
automaton.getInputAlphabet()) {
125 for(
const auto& state :
automaton.getStates()) {
134 composeTransitionsFromState(output,
automaton, state);
140template <
class SymbolType,
class StateType >
144 if ( toStates.empty ( ) ) {
148 for(
const auto & transition : toStates ) {
149 output << (sign ?
"|" :
" ");
static Token next(ext::istream &input)
Definition: AutomatonFromStringLexer.cpp:12
@ MULTI_INITIAL_STATE_NFA
Nondeterministic finite automaton with multiple initial states. Accepts regular languages.
Definition: MultiInitialStateNFA.h:69
Basic exception from which all other exceptions are derived.
Definition: CommonException.h:21
static Token peek(ext::istream &input)
Definition: lexer.hpp:53
static void putback(ext::istream &input, const Token &token)
Definition: lexer.hpp:61
Class extending the vector class from the standard library. Original reason is to allow printing of t...
Definition: vector.hpp:45
auto begin() &
Inherited behavior of begin for non-const instance.
Definition: vector.hpp:125
typename std::vector< T, Alloc >::const_iterator const_iterator
The type of constant values iterator.
Definition: vector.hpp:67
auto end() &
Inherited behavior of end for non-const instance.
Definition: vector.hpp:155
typename T::StateType StateType
Definition: ToGrammarLeftRG.h:64
typename T::SymbolType SymbolType
Definition: ReachableStates.h:176
return res
Definition: MinimizeByPartitioning.h:145
Definition: ToGrammar.h:31
Definition: normalize.hpp:10
constexpr auto make_pair(T1 &&x, T2 &&y)
Definition: pair.hpp:79
static void initialFinalState(ext::istream &input, bool &rightArrow, bool &leftArrow)
Definition: AutomatonFromStringParserCommon.cpp:10
Definition: stringApi.hpp:26