From 816c7efe7ada1554f0d62282517b6051724c7102 Mon Sep 17 00:00:00 2001 From: redpony Date: Wed, 10 Nov 2010 22:43:29 +0000 Subject: forgotten files git-svn-id: https://ws10smt.googlecode.com/svn/trunk@707 ec762483-ff6d-05da-a07a-a48fb63a330f --- klm/lm/lm_exception.hh | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 klm/lm/lm_exception.hh (limited to 'klm/lm/lm_exception.hh') diff --git a/klm/lm/lm_exception.hh b/klm/lm/lm_exception.hh new file mode 100644 index 00000000..1216c4c7 --- /dev/null +++ b/klm/lm/lm_exception.hh @@ -0,0 +1,42 @@ +#ifndef LM_LM_EXCEPTION__ +#define LM_LM_EXCEPTION__ + +// Named to avoid conflict with util/exception.hh. + +#include "util/exception.hh" +#include "util/string_piece.hh" + +#include +#include + +namespace lm { + +class LoadException : public util::Exception { + public: + virtual ~LoadException() throw(); + + protected: + LoadException() throw(); +}; + +class VocabLoadException : public LoadException { + public: + virtual ~VocabLoadException() throw(); + VocabLoadException() throw(); +}; + +class FormatLoadException : public LoadException { + public: + FormatLoadException() throw(); + ~FormatLoadException() throw(); +}; + +class SpecialWordMissingException : public VocabLoadException { + public: + explicit SpecialWordMissingException(StringPiece which) throw(); + ~SpecialWordMissingException() throw(); +}; + +} // namespace lm + +#endif // LM_LM_EXCEPTION -- cgit v1.2.3