00001 #ifndef PSSHMEMINPUT_EXCEPTIONS_H
00002 #define PSSHMEMINPUT_EXCEPTIONS_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016 #include <string>
00017 #include <cerrno>
00018 #include <boost/lexical_cast.hpp>
00019
00020
00021
00022
00023 #include "ErrSvc/Issue.h"
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048 namespace PSShmemInput {
00049
00050 class Exception : public ErrSvc::Issue {
00051 public:
00052
00053
00054 Exception ( const ErrSvc::Context& ctx,
00055 const std::string& className,
00056 const std::string& what )
00057 : ErrSvc::Issue(ctx, className+": "+what)
00058 {}
00059
00060 };
00061
00062
00063 class EmptyInputList : public Exception {
00064 public:
00065
00066 EmptyInputList(const ErrSvc::Context& ctx)
00067 : Exception( ctx, "EmptyInputList", "No input source name specified" ) {}
00068
00069 };
00070
00071
00072 class DatasetSpecError : public Exception {
00073 public:
00074
00075 DatasetSpecError(const ErrSvc::Context& ctx, const std::string& err, const std::string& spec)
00076 : Exception( ctx, "DatasetSpecError", "Dataset specification error: " + err + " (" + spec + ")" ) {}
00077
00078 };
00079
00080 }
00081
00082 #endif // PSSHMEMINPUT_EXCEPTIONS_H