Empirical
Public Member Functions | List of all members
emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE > Class Template Reference

Information about the current full state (i.e., set of legal states) of an NFA. More...

#include <NFA.h>

Public Member Functions

 tNFA_State (const tNFA< NUM_SYMBOLS, STOP_TYPE > &_nfa)
 
 ~tNFA_State ()
 
const tNFA< NUM_SYMBOLS, STOP_TYPE > & GetNFA () const
 Get the NFA associated with this state. More...
 
const std::set< size_t > & GetStateSet () const
 Get a set of states that are currently active. More...
 
bool IsActive () const
 Are there currently any legal NFA states? More...
 
bool IsStop () const
 Can we legally stop in any of the current states? More...
 
bool HasState (size_t id)
 Is a particular NFA state currently included? More...
 
size_t GetSize ()
 How many states are currently included? More...
 
void SetStateSet (const std::set< size_t > &in)
 Set the current states. More...
 
void Reset ()
 Change current states to start + free transitions from start. More...
 
void Next (size_t sym)
 Update states given a new input symbol. More...
 
void Next (const std::string &sym_set)
 Update states given a new series of input symbols (as a string) More...
 
void Print ()
 Print out current information about this NFA State (for debugging) More...
 

Detailed Description

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
class emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >

Information about the current full state (i.e., set of legal states) of an NFA.

Constructor & Destructor Documentation

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::tNFA_State ( const tNFA< NUM_SYMBOLS, STOP_TYPE > &  _nfa)
inline
template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::~tNFA_State ( )
inline

Member Function Documentation

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
const tNFA<NUM_SYMBOLS,STOP_TYPE>& emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::GetNFA ( ) const
inline

Get the NFA associated with this state.

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
size_t emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::GetSize ( )
inline

How many states are currently included?

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
const std::set<size_t>& emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::GetStateSet ( ) const
inline

Get a set of states that are currently active.

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
bool emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::HasState ( size_t  id)
inline

Is a particular NFA state currently included?

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
bool emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::IsActive ( ) const
inline

Are there currently any legal NFA states?

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
bool emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::IsStop ( ) const
inline

Can we legally stop in any of the current states?

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
void emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::Next ( size_t  sym)
inline

Update states given a new input symbol.

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
void emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::Next ( const std::string &  sym_set)
inline

Update states given a new series of input symbols (as a string)

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
void emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::Print ( )
inline

Print out current information about this NFA State (for debugging)

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
void emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::Reset ( )
inline

Change current states to start + free transitions from start.

template<size_t NUM_SYMBOLS = 128, typename STOP_TYPE = uint8_t>
void emp::tNFA_State< NUM_SYMBOLS, STOP_TYPE >::SetStateSet ( const std::set< size_t > &  in)
inline

Set the current states.


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