regal::Alphabet< Sigma > Class Template Reference

#include <Alphabet.hpp>

List of all members.

Public Member Functions

 Alphabet (Sigma *l, const int &s)
 Alphabet ()
std::list< Sigma > getList ()
int getNumericalValue (const Sigma &val)
int getSize () const
void insert (const Sigma &elt)
virtual ~Alphabet ()

Friends

std::ostream & operator<< (std::ostream &o, const Alphabet< char > &a)

template<typename Sigma>
class regal::Alphabet< Sigma >


Constructor & Destructor Documentation

template<typename Sigma>
regal::Alphabet< Sigma >::Alphabet (  )  [inline]

Default constructor of the alphabet

template<typename Sigma>
regal::Alphabet< Sigma >::Alphabet ( Sigma *  l,
const int &  s 
) [inline]

Build an alphabet with a list of letters.

Parameters:
l is a tabular of template parameters, which is supposed to contain the alphabet
s is the tabular's size.

template<typename Sigma>
virtual regal::Alphabet< Sigma >::~Alphabet (  )  [inline, virtual]

Destroy the alphabet


Member Function Documentation

template<typename Sigma>
std::list<Sigma> regal::Alphabet< Sigma >::getList (  )  [inline]

Returns the alphabet as a list of template parameters.

Returns:
the alphabet as a list of template parameters.

template<typename Sigma>
int regal::Alphabet< Sigma >::getNumericalValue ( const Sigma &  val  )  [inline]

Since every element is a template parameter, we use a map to associate the letters with an integer.

Parameters:
val is a letter already in the alphabet
Returns:
is the integer value associated to val

template<typename Sigma>
int regal::Alphabet< Sigma >::getSize (  )  const [inline]

Returns the current size of the alphabet

Returns:
the current size of the alphabet

template<typename Sigma>
void regal::Alphabet< Sigma >::insert ( const Sigma &  elt  )  [inline]

Adds a letters in the Alphabet

Parameters:
elt is the element to add.


Friends And Related Function Documentation

template<typename Sigma>
std::ostream& operator<< ( std::ostream &  o,
const Alphabet< char > &  a 
) [friend]

Print an Alphabet

Parameters:
o is the stream in which we add the DFA's description
a is the Alphabet we want to print
Returns:
the modified stream


The documentation for this class was generated from the following file:
Generated on Mon Sep 29 16:33:59 2008 for REGAL by  doxygen 1.5.1