Empirical
Classes | Namespaces | Functions
lexer_utils.h File Reference

A set of utilities to convert between NFAs and DFAs. More...

#include <map>
#include <utility>
#include "../base/vector.h"
#include "BitVector.h"
#include "DFA.h"
#include "NFA.h"

Go to the source code of this file.

Classes

struct  emp::DFAStatus
 Structure to track the current status of a DFA. More...
 

Namespaces

 emp
 If we are in emscripten, make sure to include the header.
 

Functions

static const DFA & emp::to_DFA (const DFA &dfa)
 Converting DFA to DFA – no change needed. More...
 
static const NFA & emp::to_NFA (const NFA &nfa)
 Converting NFA to MFA – no change needed. More...
 
static DFA emp::to_DFA (const NFA &nfa, int keep_invalid=false)
 Systematic conversion of NFA to DFA... More...
 
static NFA emp::to_NFA (const DFA &dfa)
 Systematic up-conversion of DFA to NFA... More...
 
template<typename T1 >
static NFA emp::MergeNFA (T1 &&in)
 Merge multiple automata into one NFA (base case, single converstion) More...
 
template<typename T1 , typename T2 , typename... Ts>
static NFA emp::MergeNFA (T1 &&in1, T2 &&in2, Ts &&...others)
 Merge multiple automata (DFA, NFA, RegEx) into one NFA. More...
 
template<typename T1 , typename T2 , typename... Ts>
static DFA emp::MergeDFA (T1 &&in1, T2 &&in2, Ts &&...others)
 Merge multiple automata (DFA, NFA, RegEx) into one DFA. More...
 
std::string emp::FindExample (const DFA &dfa, const size_t min_size=1)
 Method to find an example string that satisfies a DFA. More...
 

Detailed Description

A set of utilities to convert between NFAs and DFAs.

Note
This file is part of Empirical, https://github.com/devosoft/Empirical
Date
2016-2017
Note
Status: BETA