/usr/include/CLucene/debug/lucenebase.h is in libclucene-dev 2.3.3.4+dfsg-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | /*------------------------------------------------------------------------------
* 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_
#include "CLucene/LuceneThreads.h"
CL_NS_DEF(debug)
//Lucenebase is the superclass of all clucene objects. It provides
//memory debugging tracking and/or reference counting
class CLUCENE_EXPORT LuceneBase{
public:
_LUCENE_ATOMIC_INT __cl_refcount;
LuceneBase(){
_LUCENE_ATOMIC_INT_SET(__cl_refcount,1);
}
inline int __cl_getref(){
return _LUCENE_ATOMIC_INT_GET(__cl_refcount);
}
inline int __cl_addref(){ return _LUCENE_ATOMIC_INC(&__cl_refcount); }
inline int __cl_decref(){ return _LUCENE_ATOMIC_DEC(&__cl_refcount); }
virtual ~LuceneBase(){};
};
class CLUCENE_EXPORT LuceneVoidBase{
public:
virtual ~LuceneVoidBase(){};
};
#if defined(LUCENE_ENABLE_REFCOUNT)
#define LUCENE_BASE public CL_NS(debug)::LuceneBase
#else
#define LUCENE_BASE public CL_NS(debug)::LuceneVoidBase
#endif
#define LUCENE_REFBASE public CL_NS(debug)::LuceneBase //this is the base of classes who *always* need refcounting
CL_NS_END
#endif //_lucene_debug_lucenebase_
|