5 #ifndef BPP_SEQ_ALPHABET_ALPHABETEXCEPTIONS_H
6 #define BPP_SEQ_ALPHABET_ALPHABETEXCEPTIONS_H
43 AlphabetException(
const std::string& text, std::shared_ptr<const Alphabet> alpha);
52 Exception::operator=(ae);
94 BadCharException(
const std::string& badChar,
const std::string& text, std::shared_ptr<const Alphabet> alpha);
131 BadIntException(
int badInt,
const std::string& text, std::shared_ptr<const Alphabet> alpha);
166 const std::string& text,
178 const std::string& text,
179 std::shared_ptr<const Alphabet> alpha1,
180 std::shared_ptr<const Alphabet> alpha2);
190 Exception::operator=(ame);
The alphabet exception base class.
AlphabetException(const std::string &text, const Alphabet *alpha)
Build a new AlphabetException object.
const Alphabet * alphabet_
virtual ~AlphabetException()
AlphabetException(const AlphabetException &ae)
virtual const Alphabet * getAlphabet() const
Get the alphabet that threw the exception.
AlphabetException & operator=(const AlphabetException &ae)
Exception thrown when two alphabets do not match.
AlphabetMismatchException(const std::string &text, const Alphabet *alpha1, const Alphabet *alpha2)
Build a new AlphabetMismatchException object.
const Alphabet * alphabet1_
const Alphabet * alphabet2_
const Alphabet * getSecondAlphabet() const
Get the second alphabet.
AlphabetMismatchException & operator=(const AlphabetMismatchException &ame)
AlphabetMismatchException(const AlphabetMismatchException &ame)
const Alphabet * getFirstAlphabet() const
Get the first alphabet.
virtual ~AlphabetMismatchException()
An alphabet exception thrown when trying to specify a bad char to the alphabet.
virtual std::string getBadChar() const
Get the character that threw the exception.
virtual ~BadCharException()
BadCharException(const std::string &badChar, const std::string &text, const Alphabet *alpha)
Build a new BadCharException.
An alphabet exception thrown when trying to specify a bad int to the alphabet.
virtual int getBadInt() const
Get the integer that threw the exception.
BadIntException(int badInt, const std::string &text, const Alphabet *alpha)
Build a new BadIntException.
virtual ~BadIntException()
Exception thrown in case no character is available for a certain state in an alphabet.
virtual ~CharStateNotSupportedException()
CharStateNotSupportedException(const std::string &text, const Alphabet *alpha)
Build a new CharStateNotSupportedException.
This alphabet is used to deal NumericAlphabet.