>xabsl | The Extensible Agent Behavior Specification Language |
start | team | language reference | tools | xabsl engine | download | licence | |
XabslEngine Class Library Reference | |
  | |
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members
XabslTools.cppGo to the documentation of this file.00001 /** 00002 * @file XabslTools.cpp 00003 * 00004 * Implementation of several helper classes for the Engine. 00005 * 00006 * @author <a href="http://www.martin-loetzsch.de">Martin Loetzsch</a> 00007 */ 00008 00009 #include "XabslTools.h" 00010 #include <stdarg.h> 00011 #include <string.h> 00012 #include <stdio.h> 00013 00014 namespace xabsl 00015 { 00016 00017 void ErrorHandler::error(const char* format, ...) 00018 { 00019 // get the argument list 00020 va_list args; 00021 va_start(args,format); 00022 00023 // print the expression to the buffer 00024 vsprintf(messageBuffer,format,args); 00025 00026 printError(messageBuffer); 00027 00028 // delete the argument list 00029 va_end(args); 00030 errorsOccurred = true; 00031 } 00032 00033 void ErrorHandler::message(const char* format, ...) 00034 { 00035 // get the argument list 00036 va_list args; 00037 va_start(args,format); 00038 00039 // print the expression to the buffer 00040 vsprintf(messageBuffer,format,args); 00041 00042 printMessage(messageBuffer); 00043 00044 // delete the argument list 00045 va_end(args); 00046 } 00047 00048 } // namespace 00049 Up | Main Page | Generated at Wed Aug 19 17:32:29 2009.
|
|
Copyright 2002 - 2009 by the XABSL developer team. See the licence for details. | |