/*------------------------------------------------------------------------------ * Copyright (C) 2003-2006 Ben van Klinken and the CLucene Team * * Distributable under the terms of either the Apache License (Version 2.0) or * the GNU Lesser General Public License, as specified in the COPYING file. ------------------------------------------------------------------------------*/ #ifndef _lucene_debug_lucenebase_ #define _lucene_debug_lucenebase_ #ifdef _LUCENE_PRAGMA_ONCE # pragma once #endif CL_NS_DEF(debug) //Lucenebase is the superclass of all clucene objects. It provides //memory debugging tracking and/or reference counting class LuceneBase{ public: #ifdef LUCENE_ENABLE_MEMLEAKTRACKING static void* operator new (size_t size); static void operator delete (void *p); int32_t __cl_initnum; ///< The order that the object was created at. This is then used to do a lookup in the objects list static void* operator new (size_t size, char const * file, int32_t line); static void operator delete (void *p, char const * file, int32_t line); static void* __cl_voidpadd(void* data, const char* file, int line, size_t size); ///