33 m_refcount = orig.m_refcount;
43 #ifdef USE_REFERENCE_COUNTING 44 int32_t SGRefObject::ref()
46 int32_t count = m_refcount->
ref();
51 int32_t SGRefObject::ref_count()
58 int32_t SGRefObject::unref()
60 int32_t count = m_refcount->
unref();
63 SG_SGCDEBUG(
"unref() refcount %ld, obj %s (%p) destroying\n", count, this->
get_name(),
this)
73 #endif //USE_REFERENCE_COUNTING 75 #ifdef TRACE_MEMORY_ALLOCS 80 void SGRefObject::init()
82 #ifdef TRACE_MEMORY_ALLOCS 85 int32_t idx=sg_mallocs->
index_of(
this);
Class SGRefObject is a reference count based memory management class.
virtual const char * get_name() const =0
the class CMap, a map based on the hash-table. w: http://en.wikipedia.org/wiki/Hash_table ...
T * get_element_ptr(int32_t index)
int32_t index_of(const K &key)
all of classes and functions are contained in the shogun namespace