TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
DumpContext.h
Go to the documentation of this file.
1 /*****************************************************************************/
2 /* DumpContext.h Copyright (c) Ladislav Zezula 2015 */
3 /*---------------------------------------------------------------------------*/
4 /* Interface for TDumpContext */
5 /*---------------------------------------------------------------------------*/
6 /* Date Ver Who Comment */
7 /* -------- ---- --- ------- */
8 /* 16.03.15 1.00 Lad Created */
9 /*****************************************************************************/
10 
11 #ifndef __DUMP_CONTEXT_H__
12 #define __DUMP_CONTEXT_H__
13 
14 //-----------------------------------------------------------------------------
15 // Defines
16 
17 // Size of the buffer for the dump context
18 #define CASC_DUMP_BUFFER_SIZE 0x10000
19 
20 // Structure for dump context
22 {
23  TFileStream * pStream; // Pointer to the open stream
24  LPBYTE pbBufferBegin; // Begin of the dump buffer
25  LPBYTE pbBufferPtr; // Current dump buffer pointer
26  LPBYTE pbBufferEnd; // End of the dump buffer
27 
29 };
30 
31 //-----------------------------------------------------------------------------
32 // Dump context functions
33 
34 TDumpContext * CreateDumpContext(struct _TCascStorage * hs, const TCHAR * szNameFormat);
35 int dump_print(TDumpContext * dc, const char * szFormat, ...);
36 int dump_close(TDumpContext * dc);
37 
38 #endif // __DUMP_CONTEXT_H__
TDumpContext * CreateDumpContext(struct _TCascStorage *hs, const TCHAR *szNameFormat)
Definition: DumpContext.cpp:56
LPBYTE pbBufferPtr
Definition: DumpContext.h:25
char TCHAR
Definition: CascPort.h:148
BYTE * LPBYTE
Definition: CascPort.h:152
Definition: DumpContext.h:21
Definition: CascCommon.h:186
int dump_print(TDumpContext *dc, const char *szFormat,...)
Definition: DumpContext.cpp:101
LPBYTE pbBufferEnd
Definition: DumpContext.h:26
LPBYTE pbBufferBegin
Definition: DumpContext.h:24
Definition: FileStream.h:153
BYTE DumpBuffer[CASC_DUMP_BUFFER_SIZE]
Definition: DumpContext.h:28
int dump_close(TDumpContext *dc)
Definition: DumpContext.cpp:136
unsigned char BYTE
Definition: CascPort.h:136
#define CASC_DUMP_BUFFER_SIZE
Definition: DumpContext.h:18
TFileStream * pStream
Definition: DumpContext.h:23