5 #ifndef BPP_SEQ_ALPHABET_BINARYALPHABET_H
6 #define BPP_SEQ_ALPHABET_BINARYALPHABET_H
43 unsigned int getSize()
const {
return 2; }
52 std::vector<int>
getAlias(
int state)
const;
53 std::vector<std::string>
getAlias(
const std::string& state)
const;
A partial implementation of the Alphabet interface.
AbstractAlphabet & operator=(const AbstractAlphabet &alph)
int charToInt(const std::string &state) const
Give the int description of a state given its string description.
The BinaryAlphabet class, letters are 0 and 1.
BinaryAlphabet(const BinaryAlphabet &bia)
bool isUnresolved(int state) const
bool isResolvedIn(int state1, int state2) const
Tells if a given (potentially unresolved) state can be resolved in another resolved state.
bool isUnresolved(const std::string &state) const
BinaryAlphabet * clone() const
BinaryAlphabet & operator=(const BinaryAlphabet &bia)
virtual ~BinaryAlphabet()
int getUnknownCharacterCode() const
unsigned int getNumberOfTypes() const
Get the number of distinct states in alphabet (e.g. return 15 for DNA alphabet). This is the number o...
unsigned int getSize() const
Get the number of resolved states in the alphabet (e.g. return 4 for DNA alphabet)....
std::string getAlphabetType() const
Identification method.
std::vector< int > getAlias(int state) const
Get all resolved states that match a generic state.
This alphabet is used to deal NumericAlphabet.