OpenNI 1.5.2
XnLog.h
Go to the documentation of this file.
1 /****************************************************************************
2 * *
3 * OpenNI 1.x Alpha *
4 * Copyright (C) 2011 PrimeSense Ltd. *
5 * *
6 * This file is part of OpenNI. *
7 * *
8 * OpenNI is free software: you can redistribute it and/or modify *
9 * it under the terms of the GNU Lesser General Public License as published *
10 * by the Free Software Foundation, either version 3 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * OpenNI is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Lesser General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Lesser General Public License *
19 * along with OpenNI. If not, see <http://www.gnu.org/licenses/>. *
20 * *
21 ****************************************************************************/
22 #ifndef _XN_LOG_H_
23 #define _XN_LOG_H_
24 
25 //---------------------------------------------------------------------------
26 // Includes
27 //---------------------------------------------------------------------------
28 #include "XnOS.h"
29 #include "XnLogTypes.h"
30 #include "XnDump.h"
31 
32 //---------------------------------------------------------------------------
33 // Exported Function Declaration
34 //---------------------------------------------------------------------------
35 
46 
53 XN_C_API XnStatus XN_C_DECL xnLogInitFromINIFile(const XnChar* csINIFile, const XnChar* csSectionName);
54 
60 XN_C_API XnStatus XN_C_DECL xnLogInitFromXmlFile(const XnChar* strFileName);
61 
65 XN_C_API XnStatus XN_C_DECL xnLogClose();
66 
67 // @}
68 
81 XN_C_API XnStatus XN_C_DECL xnLogSetMaskMinSeverity(const XnChar* strMask, XnLogSeverity minSeverity);
82 
90 XN_C_API XnLogSeverity XN_C_DECL xnLogGetMaskMinSeverity(const XnChar* strMask);
91 
92 // @}
93 
106 XN_C_API XnStatus XN_C_DECL xnLogRegisterLogWriter(const XnLogWriter* pWriter);
107 
113 XN_C_API void XN_C_DECL xnLogUnregisterLogWriter(const XnLogWriter* pWriter);
114 
120 XN_C_API XnStatus XN_C_DECL xnLogSetConsoleOutput(XnBool bConsoleOutput);
121 
127 XN_C_API XnStatus XN_C_DECL xnLogSetFileOutput(XnBool bFileOutput);
128 
129 // @}
130 
141 
147 XN_C_API XnStatus XN_C_DECL xnLogSetLineInfo(XnBool bLineInfo);
148 
154 XN_C_API XnStatus XN_C_DECL xnLogSetOutputFolder(const XnChar* strOutputFolder);
155 
156 // @}
157 
169 XN_C_API XnLogger* XN_C_DECL xnLoggerOpen(const XnChar* strMask);
170 
183 XN_C_API void XN_C_DECL xnLoggerWrite(XnLogger* pLogger, XnLogSeverity severity, const XnChar* strFile, XnUInt32 nLine, const XnChar* strFormat, ...);
184 
192 XN_C_API void XN_C_DECL xnLoggerWriteNoEntry(XnLogger* pLogger, XnLogSeverity severity, const XnChar* strFormat, ...);
193 
205 XN_C_API void XN_C_DECL xnLoggerWriteBinaryData(XnLogger* pLogger, XnLogSeverity severity, const XnChar* strFile, XnUInt32 nLine, XnUChar* pBinData, XnUInt32 nDataSize, const XnChar* strFormat, ...);
206 
213 XN_C_API XnBool XN_C_DECL xnLoggerIsEnabled(XnLogger* pLogger, XnLogSeverity severity);
214 
220 XN_C_API void XN_C_DECL _xnLoggerClose(XnLogger* pLogger);
221 
227 #define xnLoggerClose(pLogger) \
228  { \
229  _xnLoggerClose(pLogger); \
230  pLogger = NULL; \
231  }
232 
233 #if XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_WIN32_VAARGS_STYLE
234 
237  #define xnLoggerWriteHelper(pLogger, severity, csFormat, ...) \
238  if (pLogger != NULL && severity >= pLogger->nMinSeverity) \
239  { \
240  xnLoggerWrite(pLogger, severity, __FILE__, __LINE__, csFormat, __VA_ARGS__); \
241  }
242 
246  #define xnLoggerVerbose(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_VERBOSE, csFormat, __VA_ARGS__)
247 
250  #define xnLoggerInfo(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_INFO, csFormat, __VA_ARGS__)
251 
254  #define xnLoggerWarning(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_WARNING, csFormat, __VA_ARGS__)
255 
258  #define xnLoggerError(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_ERROR, csFormat, __VA_ARGS__)
259 
268  #define XN_RETURN_WITH_LOG(pLogger, nRetVal, severity, csFormat, ...) \
269  { \
270  xnLoggerWriteHelper(pLogger, severity, csFormat, __VA_ARGS__); \
271  return (nRetVal); \
272  }
273 
281  #define XN_RETURN_WITH_WARNING_LOG(pLogger, nRetVal, csFormat, ...) \
282  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_WARNING, csFormat, __VA_ARGS__)
283 
291  #define XN_RETURN_WITH_ERROR_LOG(pLogger, nRetVal, csFormat, ...) \
292  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_ERROR, csFormat, __VA_ARGS__)
293 
294 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_GCC_VAARGS_STYLE
295  #define xnLoggerWriteHelper(pLogger, severity, csFormat, ...) \
296  if (pLogger != NULL && severity >= pLogger->nMinSeverity) \
297  { \
298  xnLoggerWrite(pLogger, severity, __FILE__, __LINE__, csFormat, ##__VA_ARGS__); \
299  }
300 
301  #define xnLoggerVerbose(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_VERBOSE, csFormat,## __VA_ARGS__)
302  #define xnLoggerInfo(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_INFO, csFormat, ##__VA_ARGS__)
303  #define xnLoggerWarning(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_WARNING, csFormat, ##__VA_ARGS__)
304  #define xnLoggerError(pLogger, csFormat, ...) xnLoggerWriteHelper(pLogger, XN_LOG_ERROR, csFormat, ##__VA_ARGS__)
305 
306  /* Writes to the log and returns nRetVal */
307  #define XN_RETURN_WITH_LOG(pLogger, nRetVal, severity, csFormat, ...) \
308  { \
309  xnLoggerWriteHelper(pLogger, severity, csFormat, ##__VA_ARGS__); \
310  return (nRetVal); \
311  }
312 
313  /* Logs a warning and returns nRetVal */
314  #define XN_RETURN_WITH_WARNING_LOG(pLogger, nRetVal, csFormat, ...) \
315  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_WARNING, csFormat, ##__VA_ARGS__)
316 
317  /* Logs an error and returns nRetVal */
318  #define XN_RETURN_WITH_ERROR_LOG(pLogger, nRetVal, csFormat, ...) \
319  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_ERROR, csFormat, ##__VA_ARGS__)
320 
321 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_ARC_VAARGS_STYLE
322  #define xnLoggerWriteHelper(pLogger, severity, csFormat...) \
323  if (pLogger != NULL && severity >= pLogger->nMinSeverity) \
324  { \
325  xnLoggerWrite(pLogger, severity, __FILE__, __LINE__, csFormat); \
326  }
327 
328  #define xnLoggerVerbose(pLogger, csFormat...) xnLoggerWriteHelper(pLogger, XN_LOG_VERBOSE, csFormat)
329  #define xnLoggerInfo(pLogger, csFormat...) xnLoggerWriteHelper(pLogger, XN_LOG_INFO, csFormat)
330  #define xnLoggerWarning(pLogger, csFormat...) xnLoggerWriteHelper(pLogger, XN_LOG_WARNING, csFormat)
331  #define xnLoggerError(pLogger, csFormat...) xnLoggerWriteHelper(pLogger, XN_LOG_ERROR, csFormat)
332 
333  /* Writes to the log and returns nRetVal */
334  #define XN_RETURN_WITH_LOG(pLogger, nRetVal, severity, csFormat...) \
335  { \
336  xnLoggerWriteHelper(pLogger, severity, csFormat); \
337  return (nRetVal); \
338  }
339 
340  /* Logs a warning and returns nRetVal */
341  #define XN_RETURN_WITH_WARNING_LOG(pLogger, nRetVal, csFormat...) \
342  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_WARNING, csFormat)
343 
344  /* Logs an error and returns nRetVal */
345  #define XN_RETURN_WITH_ERROR_LOG(pLogger, nRetVal, csFormat...) \
346  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_ERROR, csFormat)
347 
348 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_NO_VAARGS
349  #define xnLoggerWriteHelper(pLogger, severity, csFormat, arg) \
350  if (pLogger != NULL && severity >= pLogger->nMinSeverity) \
351  { \
352  xnLoggerWrite(pLogger, severity, __FILE__, __LINE__, csFormat, arg); \
353  }
354 
355  #define xnLoggerVerbose(pLogger, csFormat, arg) xnLoggerWriteHelper(pLogger, XN_LOG_VERBOSE, csFormat, arg)
356  #define xnLoggerInfo(pLogger, csFormat, arg) xnLoggerWriteHelper(pLogger, XN_LOG_INFO, csFormat, arg)
357  #define xnLoggerWarning(pLogger, csFormat, arg) xnLoggerWriteHelper(pLogger, XN_LOG_WARNING, csFormat, arg)
358  #define xnLoggerError(pLogger, csFormat, arg) xnLoggerWriteHelper(pLogger, XN_LOG_ERROR, csFormat, arg)
359 
360  /* Writes to the log and returns nRetVal */
361  #define XN_RETURN_WITH_LOG(pLogger, nRetVal, severity, csFormat) \
362  { \
363  xnLoggerWriteHelper(pLogger, severity, csFormat); \
364  return (nRetVal); \
365  }
366 
367  /* Logs a warning and returns nRetVal */
368  #define XN_RETURN_WITH_WARNING_LOG(pLogger, nRetVal, csFormat) \
369  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_WARNING, csFormat)
370 
371  /* Logs an error and returns nRetVal */
372  #define XN_RETURN_WITH_ERROR_LOG(pLogger, nRetVal, csFormat) \
373  XN_RETURN_WITH_LOG(pLogger, nRetVal, XN_LOG_ERROR, csFormat)
374 
375 #else
376  #error Xiron Log - Unknown VAARGS type!
377 #endif
378 
379 // @}
380 
393 XN_C_API XnStatus XN_C_DECL xnLogCreateFile(const XnChar* strFileName, XN_FILE_HANDLE* phFile);
394 
404 XN_C_API XnStatus XN_C_DECL xnLogCreateFileEx(const XnChar* strFileName, XnBool bSessionBased, XN_FILE_HANDLE* phFile);
405 
406 // @}
407 
408 #define XN_MASK_RETVAL_CHECKS "RetValChecks"
409 
410 #if XN_PLATFORM == XN_PLATFORM_ARC
412 #else
414 #endif
415 
417 #define XN_IS_STATUS_OK_LOG_ERROR(what, nRetVal) \
418  if (nRetVal != XN_STATUS_OK) \
419  { \
420  xnLoggerError(XN_LOGGER_RETVAL_CHECKS, "Failed to " what ": %s", xnGetStatusString(nRetVal)); \
421  XN_ASSERT(FALSE); \
422  return (nRetVal); \
423  }
424 
425 
426 #ifndef __XN_NO_BC__
427 
428 XN_C_API XnStatus XN_API_DEPRECATED("Please use xnLogSetMaskMinSeverity() instead") XN_C_DECL xnLogSetMaskState(const XnChar* csMask, XnBool bEnabled);
429 XN_C_API XnStatus XN_API_DEPRECATED("Please use xnLogSetMaskMinSeverity() instead") XN_C_DECL xnLogSetSeverityFilter(XnLogSeverity nMinSeverity);
430 XN_C_API XnBool XN_C_DECL xnLogIsEnabled(const XnChar* csLogMask, XnLogSeverity nSeverity);
431 XN_C_API void XN_C_DECL xnLogWrite(const XnChar* csLogMask, XnLogSeverity nSeverity, const XnChar* csFile, XnUInt32 nLine, const XnChar* csFormat, ...);
432 XN_C_API void XN_C_DECL xnLogWriteNoEntry(const XnChar* csLogMask, XnLogSeverity nSeverity, const XnChar* csFormat, ...);
433 XN_C_API void XN_C_DECL xnLogWriteBinaryData(const XnChar* csLogMask, XnLogSeverity nSeverity, const XnChar* csFile, XnUInt32 nLine, XnUChar* pBinData, XnUInt32 nDataSize, const XnChar* csFormat, ...);
434 
435 #if XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_WIN32_VAARGS_STYLE
436  #define xnLogVerbose(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_VERBOSE, __FILE__, __LINE__, csFormat, __VA_ARGS__)
437  #define xnLogInfo(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_INFO, __FILE__, __LINE__, csFormat, __VA_ARGS__)
438  #define xnLogWarning(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_WARNING, __FILE__, __LINE__, csFormat, __VA_ARGS__)
439  #define xnLogError(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_ERROR, __FILE__, __LINE__, csFormat, __VA_ARGS__)
440 
441  /* Writes to the log and returns nRetVal */
442  #define XN_LOG_RETURN(nRetVal, nSeverity, csLogMask, csFormat, ...) \
443  { \
444  xnLogWrite(csLogMask, nSeverity, __FILE__, __LINE__, csFormat, __VA_ARGS__); \
445  return (nRetVal); \
446  }
447 
448  /* Logs a warning and returns nRetVal */
449  #define XN_LOG_WARNING_RETURN(nRetVal, csLogMask, csFormat, ...) \
450  XN_LOG_RETURN(nRetVal, XN_LOG_WARNING, csLogMask, csFormat, __VA_ARGS__)
451 
452  /* Logs a warning and returns nRetVal */
453  #define XN_LOG_ERROR_RETURN(nRetVal, csLogMask, csFormat, ...) \
454  XN_LOG_RETURN(nRetVal, XN_LOG_ERROR, csLogMask, csFormat, __VA_ARGS__)
455 
456 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_GCC_VAARGS_STYLE
457  #define xnLogVerbose(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_VERBOSE, __FILE__, __LINE__, csFormat, ##__VA_ARGS__)
458  #define xnLogInfo(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_INFO, __FILE__, __LINE__, csFormat, ##__VA_ARGS__)
459  #define xnLogWarning(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_WARNING, __FILE__, __LINE__, csFormat, ##__VA_ARGS__)
460  #define xnLogError(csLogMask, csFormat, ...) xnLogWrite(csLogMask, XN_LOG_ERROR, __FILE__, __LINE__, csFormat, ##__VA_ARGS__)
461 
462  /* Writes to the log and returns nRetVal */
463  #define XN_LOG_RETURN(nRetVal, nSeverity, csLogMask, csFormat, ...) \
464  { \
465  xnLogWrite(csLogMask, nSeverity, __FILE__, __LINE__, csFormat, ##__VA_ARGS__); \
466  return (nRetVal); \
467  }
468 
469  /* Logs a warning and returns nRetVal */
470  #define XN_LOG_WARNING_RETURN(nRetVal, csLogMask, csFormat, ...) \
471  XN_LOG_RETURN(nRetVal, XN_LOG_WARNING, csLogMask, csFormat, ##__VA_ARGS__)
472 
473  /* Logs a warning and returns nRetVal */
474  #define XN_LOG_ERROR_RETURN(nRetVal, csLogMask, csFormat, ...) \
475  XN_LOG_RETURN(nRetVal, XN_LOG_ERROR, csLogMask, csFormat, ##__VA_ARGS__)
476 
477 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_ARC_VAARGS_STYLE
478  #define xnLogVerbose(csLogMask, csFormat...) xnLogWrite(csLogMask, XN_LOG_VERBOSE, __FILE__, __LINE__, csFormat)
479  #define xnLogInfo(csLogMask, csFormat...) xnLogWrite(csLogMask, XN_LOG_INFO, __FILE__, __LINE__, csFormat)
480  #define xnLogWarning(csLogMask, csFormat...) xnLogWrite(csLogMask, XN_LOG_WARNING, __FILE__, __LINE__, csFormat)
481  #define xnLogError(csLogMask, csFormat...) xnLogWrite(csLogMask, XN_LOG_ERROR, __FILE__, __LINE__, csFormat)
482 
483  /* Writes to the log and returns nRetVal */
484  #define XN_LOG_RETURN(nRetVal, nSeverity, csLogMask, csFormat...) \
485  { \
486  xnLogWrite(csLogMask, nSeverity, __FILE__, __LINE__, csFormat); \
487  return (nRetVal); \
488  }
489 
490  /* Logs a warning and returns nRetVal */
491  #define XN_LOG_WARNING_RETURN(nRetVal, csLogMask, csFormat...) \
492  XN_LOG_RETURN(nRetVal, XN_LOG_WARNING, csLogMask, csFormat)
493 
494  /* Logs a warning and returns nRetVal */
495  #define XN_LOG_ERROR_RETURN(nRetVal, csLogMask, csFormat...) \
496  XN_LOG_RETURN(nRetVal, XN_LOG_ERROR, csLogMask, csFormat)
497 
498  /* If nRetVal is not ok, writes to the log and returns nRetVal */
499  #define XN_IS_STATUS_OK_LOG(nRetVal, nSeverity, csLogMask, csFormat...) \
500  if (nRetVal != XN_STATUS_OK) \
501  { \
502  XN_LOG_RETURN(nRetVal, nSeverity, csLogMask, csFormat) \
503  }
504 
505  /* If nRetVal is not ok, logs a warning and returns nRetVal */
506  #define XN_IS_STATUS_OK_WARNING(nRetVal, csLogMask, csFormat...) \
507  XN_IS_STATUS_OK_LOG(nRetVal, XN_LOG_WARNING, csLogMask, csFormat)
508 
509  /* If nRetVal is not ok, logs an error and returns nRetVal */
510  #define XN_IS_STATUS_OK_ERROR(nRetVal, csLogMask, csFormat...) \
511  XN_IS_STATUS_OK_LOG(nRetVal, XN_LOG_ERROR, csLogMask, csFormat)
512 
513 #elif XN_PLATFORM_VAARGS_TYPE == XN_PLATFORM_USE_NO_VAARGS
514  #define xnLogVerbose(csLogMask, csFormat, args) xnLogWrite(csLogMask, XN_LOG_VERBOSE, __FILE__, __LINE__, csFormat, args)
515  #define xnLogInfo(csLogMask, csFormat, args) xnLogWrite(csLogMask, XN_LOG_INFO, __FILE__, __LINE__, csFormat, args)
516  #define xnLogWarning(csLogMask, csFormat, args) xnLogWrite(csLogMask, XN_LOG_WARNING, __FILE__, __LINE__, csFormat, args)
517  #define xnLogError(csLogMask, csFormat, args) xnLogWrite(csLogMask, XN_LOG_ERROR, __FILE__, __LINE__, csFormat, args)
518 
519  /* Writes to the log and returns nRetVal */
520  #define XN_LOG_RETURN(nRetVal, nSeverity csLogMask, csFormat, args) \
521  { \
522  xnLogWrite(csLogMask, nSeverity, __FILE__, __LINE__, csFormat, args); \
523  return (nRetVal); \
524  }
525 
526  /* Logs a warning and returns nRetVal */
527  #define XN_LOG_WARNING_RETURN(nRetVal, csLogMask, csFormat, args) \
528  XN_LOG_RETURN(nRetVal, XN_LOG_WARNING, csLogMask, csFormat, args)
529 
530  /* Logs an error and returns nRetVal */
531  #define XN_LOG_ERROR_RETURN(nRetVal, csLogMask, csFormat, args) \
532  XN_LOG_RETURN(nRetVal, XN_LOG_ERROR, csLogMask, csFormat, args)
533 
534 #else
535  #error Xiron Log - Unknown VAARGS type!
536 #endif
537 
538 #endif // ifndef __XN_NO_BC__
539 
540 #endif //_XN_LOG_H_
541 
XN_C_API XnStatus XN_C_DECL xnLogCreateFileEx(const XnChar *strFileName, XnBool bSessionBased, XN_FILE_HANDLE *phFile)
XN_C_API void XN_C_DECL xnLoggerWriteBinaryData(XnLogger *pLogger, XnLogSeverity severity, const XnChar *strFile, XnUInt32 nLine, XnUChar *pBinData, XnUInt32 nDataSize, const XnChar *strFormat,...)
XnLogSeverity
Definition: XnLogTypes.h:42
XN_C_API void XN_C_DECL xnLoggerWriteNoEntry(XnLogger *pLogger, XnLogSeverity severity, const XnChar *strFormat,...)
XN_C_API XnStatus XN_C_DECL xnLogSetLineInfo(XnBool bLineInfo)
XN_C_API XnStatus XN_C_DECL xnLogStartNewFile()
XnUInt32 XnStatus
Definition: XnStatus.h:34
XN_C_API void XN_C_DECL xnLogUnregisterLogWriter(const XnLogWriter *pWriter)
Definition: XnLogTypes.h:71
XN_C_API XnLogger *XN_C_DECL xnLoggerOpen(const XnChar *strMask)
XN_C_API XnStatus XN_C_DECL xnLogInitFromINIFile(const XnChar *csINIFile, const XnChar *csSectionName)
XN_C_API XnStatus XN_C_DECL xnLogSetMaskMinSeverity(const XnChar *strMask, XnLogSeverity minSeverity)
XN_C_API XnStatus XN_C_DECL xnLogSetConsoleOutput(XnBool bConsoleOutput)
XN_C_API XnStatus XN_C_DECL xnLogInitFromXmlFile(const XnChar *strFileName)
XN_C_API XnLogSeverity XN_C_DECL xnLogGetMaskMinSeverity(const XnChar *strMask)
#define XN_C_API
Definition: XnPlatform.h:114
XN_C_API XnStatus XN_C_DECL xnLogSetFileOutput(XnBool bFileOutput)
XN_C_API XnStatus XN_C_DECL xnLogCreateFile(const XnChar *strFileName, XN_FILE_HANDLE *phFile)
XN_C_API XnStatus XN_C_DECL xnLogRegisterLogWriter(const XnLogWriter *pWriter)
XN_C_API XnStatus XN_C_DECL xnLogInitSystem()
XN_C_API XnLogger * XN_LOGGER_RETVAL_CHECKS
Definition: XnLog.h:413
Definition: XnLogTypes.h:54
XN_C_API void XN_C_DECL xnLoggerWrite(XnLogger *pLogger, XnLogSeverity severity, const XnChar *strFile, XnUInt32 nLine, const XnChar *strFormat,...)
XN_C_API XnStatus XN_C_DECL xnLogSetOutputFolder(const XnChar *strOutputFolder)
XN_C_API XnStatus XN_C_DECL xnLogClose()
XN_C_API XnBool XN_C_DECL xnLoggerIsEnabled(XnLogger *pLogger, XnLogSeverity severity)