Algorithms Library Toolkit
A toolkit for algorithms, especially for algorithms on formal languages
Data Structures | Static Public Member Functions
regexp::convert::ToAutomatonThompson Class Reference

#include <ToAutomatonThompson.h>

Data Structures

class  Formal
 
class  Unbounded
 

Static Public Member Functions

static automaton::EpsilonNFA< > convert (const regexp::FormalRegExp< > &regexp)
 
static automaton::EpsilonNFA< > convert (const regexp::UnboundedRegExp< > &regexp)
 

Detailed Description

Converts regular expression to finite automaton using Thompson's Construction Algorithm (TCA). Sources: Hopcroft, section 3.2.3 http://www.eecis.udel.edu/~cavazos/cisc672/lectures/Lecture-04.pdf http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.21.7450&rep=rep1&type=ps Melichar 2.112

Member Function Documentation

◆ convert() [1/2]

automaton::EpsilonNFA< > regexp::convert::ToAutomatonThompson::convert ( const regexp::FormalRegExp< > &  regexp)
static

Implements conversion of regular expressions to finite automata using Thompson's method of incremental construction.

Template Parameters
SymbolTypethe type of symbols in the regular expression
Parameters
regexpthe regexp to convert
Returns
finite automaton accepting the language described by the original regular expression

◆ convert() [2/2]

automaton::EpsilonNFA< > regexp::convert::ToAutomatonThompson::convert ( const regexp::UnboundedRegExp< > &  regexp)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.


The documentation for this class was generated from the following files: