Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

ippParserCmdErrorId.cpp

Go to the documentation of this file.
00001 
00002 #include "stdafx.h"
00003 #include "ippdme/Parser/ippParserCmdErrorId.h"
00004 
00005 #define ENUMERATION                                                                                      \
00006 IPP_ENUM_VALUE(OK                                                         ,(ippErrorNameType_)-1)  \
00007 IPP_ENUM_VALUE(ARGUMENT_FIRST_PART_MUST_BE_TOOL_OR_FOUNDTOOL              ,BadArgument)\
00008 IPP_ENUM_VALUE(ARGUMENT_FOURTH_PART_MUST_BE_ACT                           ,BadArgument)\
00009 IPP_ENUM_VALUE(ARGUMENT_FOURTH_PART_BAD                                   ,BadArgument)\
00010 IPP_ENUM_VALUE(ARGUMENT_MUST_BE_A_NUMBER                                  ,BadArgument)\
00011 IPP_ENUM_VALUE(ARGUMENT_MUST_BE_EVENT_TAG                                 ,BadArgument)\
00012 IPP_ENUM_VALUE(ARGUMENT_MUST_BE_INTEGER                                   ,BadArgument)\
00013 IPP_ENUM_VALUE(ARGUMENT_MUST_BE_POSITIVE                                  ,BadArgument)\
00014 IPP_ENUM_VALUE(ARGUMENT_MUST_BE_STRING                                    ,BadArgument)\
00015 IPP_ENUM_VALUE(ARGUMENT_MUST_END_WITH_EMPTY_PARENTHESES                   ,BadArgument)\
00016 IPP_ENUM_VALUE(ARGUMENT_MUST_END_WITH_NUMBER_IN_PARENTHESES               ,BadArgument)\
00017 IPP_ENUM_VALUE(ARGUMENT_SECOND_PART_BAD                                   ,BadArgument)\
00018 IPP_ENUM_VALUE(ARGUMENT_SECOND_PART_MUST_BE_GOTOPAR_OR_PTMEASPAR          ,BadArgument)\
00019 IPP_ENUM_VALUE(ARGUMENT_THIRD_PART_BAD                                    ,BadArgument)\
00020 IPP_ENUM_VALUE(BAD_ARGUMENTS                                              ,IncorrectArguments)\
00021 IPP_ENUM_VALUE(BAD_CHARACTER_AFTER_COMMAND_END                            ,IllegalCommand)\
00022 IPP_ENUM_VALUE(BAD_CHARACTER_AFTER_KEYWORD                                ,IncorrectArguments)\
00023 IPP_ENUM_VALUE(BAD_COMMAND_ARGUMENTS                                      ,IncorrectArguments)\
00024 IPP_ENUM_VALUE(BAD_COMMAND_NAME                                           ,IllegalCommand)\
00025 IPP_ENUM_VALUE(BAD_DOTS                                                   ,IncorrectArguments)\
00026 IPP_ENUM_VALUE(BAD_E_NUMBER_EXPONENT_MUST_HAVE_ONE_TWO_OR_THREE_DIGITS    ,BadArgument)\
00027 IPP_ENUM_VALUE(BAD_FIRST_ARGUMENT                                         ,BadArgument)\
00028 IPP_ENUM_VALUE(BAD_IJK_NUMBERS                                            ,IncorrectArguments)\
00029 IPP_ENUM_VALUE(BAD_KEYWORD                                                ,IncorrectArguments)\
00030 IPP_ENUM_VALUE(BAD_NUMBER_MORE_THAN_16_DIGITS                             ,BadArgument)\
00031 IPP_ENUM_VALUE(BAD_NUMBER_NO_DIGITS                                       ,BadArgument)\
00032 IPP_ENUM_VALUE(BAD_NUMBER_OF_THROUGHS                                     ,BadArgument)\
00033 IPP_ENUM_VALUE(BAD_NUMBER_TWO_DECIMAL_POINTS                              ,BadArgument)\
00034 IPP_ENUM_VALUE(BAD_STRING                                                 ,BadArgument)\
00035 IPP_ENUM_VALUE(BAD_TAG_CHARACTER                                          ,IllegalTag)\
00036 IPP_ENUM_VALUE(C_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00037 IPP_ENUM_VALUE(DIAMETER_MUST_BE_POSITIVE                                  ,BadArgument)\
00038 IPP_ENUM_VALUE(DIS_ARGUMENT_USED_TWICE                                    ,IncorrectArguments)\
00039 IPP_ENUM_VALUE(DIS_MUST_BE_FOLLOWED_BY_NUMBER_IN_PARENS                   ,BadArgument)\
00040 IPP_ENUM_VALUE(ER_ARGUMENT_USED_TWICE                                     ,IncorrectArguments)\
00041 IPP_ENUM_VALUE(EVENT_COMMAND_MUST_HAVE_EVENT_TAG                          ,IllegalTag)\
00042 IPP_ENUM_VALUE(IJK_ARGUMENT_USED_TWICE                                    ,IncorrectArguments)\
00043 IPP_ENUM_VALUE(IJK_NOT_FOLLOWED_BY_ARGIJK                                 ,IncorrectArguments)\
00044 IPP_ENUM_VALUE(LMN_ARGUMENT_USED_TWICE                                    ,IncorrectArguments)\
00045 IPP_ENUM_VALUE(LMN_NOT_FOLLOWED_BY_ARGIJK                                 ,IncorrectArguments)\
00046 IPP_ENUM_VALUE(ILLEGAL_SPACE                                              ,IncorrectArguments)\
00047 IPP_ENUM_VALUE(MUST_HAVE_NO_ARGUMENTS                                     ,IncorrectArguments)\
00048 IPP_ENUM_VALUE(MUST_HAVE_ONE_ARGUMENT                                     ,IncorrectArguments)\
00049 IPP_ENUM_VALUE(MUST_HAVE_4_ARGUMENTS                                      ,IncorrectArguments)\
00050 IPP_ENUM_VALUE(MUST_HAVE_4_OR_8_ARGUMENTS                                 ,IncorrectArguments)\
00051 IPP_ENUM_VALUE(MUST_HAVE_7_ARGUMENTS                                      ,IncorrectArguments)\
00052 IPP_ENUM_VALUE(MUST_HAVE_7_OR_14_ARGUMENTS                                ,IncorrectArguments)\
00053 IPP_ENUM_VALUE(NON_EVENT_COMMAND_MUST_NOT_HAVE_EVENT_TAG                  ,IllegalTag)\
00054 IPP_ENUM_VALUE(NUMBER_THROUGH_MUST_BE_INTEGER                             ,BadArgument)\
00055 IPP_ENUM_VALUE(NUMBER_THROUGH_MUST_BE_POSITIVE                            ,BadArgument)\
00056 IPP_ENUM_VALUE(PHI_ARGUMENT_USED_TWICE                                    ,IncorrectArguments)\
00057 IPP_ENUM_VALUE(Q_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00058 IPP_ENUM_VALUE(R_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00059 IPP_ENUM_VALUE(SPACE_MISSING_AFTER_TAG                                    ,NoSpaceAtPos6)\
00060 IPP_ENUM_VALUE(STEPW_MUST_BE_POSITIVE                                     ,BadArgument)\
00061 IPP_ENUM_VALUE(TAG_NUMBER_OUT_OF_RANGE_FOR_EVENT_TAG                      ,IllegalTag)\
00062 IPP_ENUM_VALUE(TAG_NUMBER_OUT_OF_RANGE_FOR_COMMAND_TAG                    ,IllegalTag)\
00063 IPP_ENUM_VALUE(THETA_OUT_OF_RANGE                                         ,ThetaOutOfRange)\
00064 IPP_ENUM_VALUE(TIME_ARGUMENT_USED_TWICE                                   ,IncorrectArguments)\
00065 IPP_ENUM_VALUE(TIME_MUST_BE_FOLLOWED_BY_NUMBER_IN_PARENS                  ,BadArgument)\
00066 IPP_ENUM_VALUE(TOOL_A_ARGUMENT_USED_TWICE                                 ,IncorrectArguments)\
00067 IPP_ENUM_VALUE(TOOL_B_ARGUMENT_USED_TWICE                                 ,IncorrectArguments)\
00068 IPP_ENUM_VALUE(TOOL_C_ARGUMENT_USED_TWICE                                 ,IncorrectArguments)\
00069 IPP_ENUM_VALUE(X_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00070 IPP_ENUM_VALUE(X_NOT_FOLLOWED_BY_NUMBER_IN_PARENS                         ,BadArgument)\
00071 IPP_ENUM_VALUE(X_Y_Z_ALL_MISSING                                          ,IncorrectArguments)\
00072 IPP_ENUM_VALUE(Y_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00073 IPP_ENUM_VALUE(Y_NOT_FOLLOWED_BY_NUMBER_IN_PARENS                         ,BadArgument)\
00074 IPP_ENUM_VALUE(Z_ARGUMENT_USED_TWICE                                      ,IncorrectArguments)\
00075 IPP_ENUM_VALUE(Z_NOT_FOLLOWED_BY_NUMBER_IN_PARENS                         ,BadArgument)\
00076 IPP_ENUM_VALUE(BAD_SYNTAX_FOR_FORMAT_IN_SCANONCURVE                       ,BadArgument)\
00077 IPP_ENUM_VALUE(BAD_NUMBER_OF_ARGUMENT_FOR_DATA_IN_SCANONCURVE             ,BadArgument)\
00078   
00079 
00080 
00081 const char * toString(ippParserCmdErrorId v)
00082 {
00083   switch(v)                    
00084   {
00085 #define IPP_ENUM_VALUE(X,Y) case X : return #X;
00086      ENUMERATION
00087   default:
00088     return"";
00089   }
00090 #undef  IPP_ENUM_VALUE
00091 }
00092 
00093 
00094 /*static*/ 
00095 ippErrorNameType getIppErr(ippParserCmdErrorId code)
00096 {
00097   switch(code)                    
00098   {
00099 #define IPP_ENUM_VALUE(X,Y) case X : return Y;
00100      ENUMERATION
00101   default:
00102     return BadArgument;
00103   }
00104 #undef  IPP_ENUM_VALUE
00105 
00106 } 
00107  

Generated on Wed Nov 8 00:20:05 2006 for IPPDME by  doxygen 1.4.1