OpenClonk
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
C4MCParserErr Class Reference

#include <C4MapCreatorS2.h>

Public Member Functions

 C4MCParserErr (C4MCParser *pParser, const char *szMsg)
 
 C4MCParserErr (C4MCParser *pParser, const char *szMsg, const char *szPar)
 
void show ()
 

Public Attributes

char Msg [C4MaxMessage]
 

Detailed Description

Definition at line 344 of file C4MapCreatorS2.h.

Constructor & Destructor Documentation

C4MCParserErr::C4MCParserErr ( C4MCParser pParser,
const char *  szMsg 
)

Definition at line 906 of file C4MapCreatorS2.cpp.

References Msg, SGetLine(), and sprintf.

907 {
908  // create error message
909  sprintf(Msg, "%s: %s (%d)", pParser->Filename, szMsg, pParser->BPos ? SGetLine(pParser->BPos, pParser->CPos) : 0);
910 }
#define sprintf
Definition: Standard.h:171
int SGetLine(const char *szText, const char *cpPosition)
Definition: Standard.cpp:450
char Msg[C4MaxMessage]

Here is the call graph for this function:

C4MCParserErr::C4MCParserErr ( C4MCParser pParser,
const char *  szMsg,
const char *  szPar 
)

Definition at line 912 of file C4MapCreatorS2.cpp.

References C4MaxMessage, Msg, SGetLine(), and sprintf.

913 {
914  char Buf[C4MaxMessage];
915  // create error message
916  sprintf(Buf, szMsg, szPar);
917  sprintf(Msg, "%s: %s (%d)", pParser->Filename, Buf, pParser->BPos ? SGetLine(pParser->BPos, pParser->CPos) : 0);
918 }
#define sprintf
Definition: Standard.h:171
int SGetLine(const char *szText, const char *cpPosition)
Definition: Standard.cpp:450
char Msg[C4MaxMessage]
const int C4MaxMessage
Definition: C4Constants.h:28

Here is the call graph for this function:

Member Function Documentation

void C4MCParserErr::show ( )

Definition at line 920 of file C4MapCreatorS2.cpp.

References Log(), and Msg.

Referenced by C4MapCreatorS2::ReadFile(), and C4MapCreatorS2::ReadScript().

921 {
922  // log error
923  Log(Msg);
924 }
char Msg[C4MaxMessage]
bool Log(const char *szMessage)
Definition: C4Log.cpp:195

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

char C4MCParserErr::Msg[C4MaxMessage]

Definition at line 347 of file C4MapCreatorS2.h.

Referenced by c4_mapgen_handle_new(), C4MCParserErr(), and show().


The documentation for this class was generated from the following files: