5 #ifndef BPP_SEQ_ALPHABET_LEXICALALPHABET_H
6 #define BPP_SEQ_ALPHABET_LEXICALALPHABET_H
74 return static_cast<int>(
getSize());
A partial implementation of the Alphabet interface.
unsigned int getNumberOfChars() const
Get the number of supported characters in this alphabet, including generic characters (e....
AbstractAlphabet & operator=(const AbstractAlphabet &alph)
int charToInt(const std::string &state) const
Give the int description of a state given its string description.
Alphabet made of given words.
unsigned int getNumberOfTypes() const
Get the number of distinct states in alphabet (e.g. return 15 for DNA alphabet). This is the number o...
int getUnknownCharacterCode() const
unsigned int getSize() const
Get the number of resolved states in the alphabet (e.g. return 4 for DNA alphabet)....
bool isUnresolved(int state) const
bool isUnresolved(const std::string &state) const
LexicalAlphabet & operator=(const LexicalAlphabet &bia)
LexicalAlphabet(const LexicalAlphabet &bia)
virtual ~LexicalAlphabet()
std::string getAlphabetType() const
Identification method.
LexicalAlphabet(const std::vector< std::string > &vocab)
Builds a new word alphabet from a vector of given words.
LexicalAlphabet * clone() const
This alphabet is used to deal NumericAlphabet.