PTHREAD_MUTEX_INITIALIZER, // pthread_mutex_t symHashMutex
NULL, // khash_t(allocmap)* memHash
PTHREAD_MUTEX_INITIALIZER, // pthread_mutex_t memHashMutex
+ NULL, // khash_t(uiobject)* uiobjHash
+ PTHREAD_MUTEX_INITIALIZER, // pthread_mutex_t uiobjHashMutex
NULL, // khash_t(object)* objHash
PTHREAD_MUTEX_INITIALIZER, // pthread_mutex_t objHashMutex
NULL, // khash_t(detector)* dttHash
MEMORYHASH = kh_init(allocmap);
MEMORYHASH_UNLOCK;
+ UIOBJECTHASH_LOCK;
+ UIOBJECTHASH = kh_init(uiobject);
+ UIOBJECTHASH_UNLOCK;
+
OBJECTHASH_LOCK;
OBJECTHASH = kh_init(object);
OBJECTHASH_UNLOCK;
int finalize_hash_table()
{
- if(SYMBOLHASH)
+ if (SYMBOLHASH)
{
khiter_t k;
char* val;
SYMBOLHASH_LOCK;
for(k = kh_begin(SYMBOLHASH); k != kh_end(SYMBOLHASH); k++)
{
- if(kh_exist(SYMBOLHASH, k))
+ if (kh_exist(SYMBOLHASH, k))
{
val = kh_value(SYMBOLHASH, k);
free(val);
SYMBOLHASH_UNLOCK;
}
- if(MEMORYHASH)
+ if (MEMORYHASH)
{
MEMORYHASH_LOCK;
kh_destroy(allocmap, MEMORYHASH);
MEMORYHASH_UNLOCK;
}
- if(OBJECTHASH)
+ if (UIOBJECTHASH)
{
khiter_t k;
- _objectinfo* val;
+ _uiobjectinfo* val;
- OBJECTHASH_LOCK;
- for(k = kh_begin(OBJECTHASH); k != kh_end(OBJECTHASH); k++)
+ UIOBJECTHASH_LOCK;
+ for(k = kh_begin(UIOBJECTHASH); k != kh_end(UIOBJECTHASH); k++)
{
- if(kh_exist(OBJECTHASH, k))
+ if (kh_exist(UIOBJECTHASH, k))
{
- val = kh_value(OBJECTHASH, k);
- if(likely(val->type != 0)) free(val->type);
- if(likely(val->name != 0)) free(val->name);
+ val = kh_value(UIOBJECTHASH, k);
+ if (likely(val->type != 0)) free(val->type);
+ if (likely(val->name != 0)) free(val->name);
free(val);
}
}
+ kh_destroy(uiobject, UIOBJECTHASH);
+ UIOBJECTHASH = NULL;
+ UIOBJECTHASH_UNLOCK;
+ }
+
+ if (OBJECTHASH)
+ {
+ OBJECTHASH_LOCK;
kh_destroy(object, OBJECTHASH);
OBJECTHASH = NULL;
OBJECTHASH_UNLOCK;
}
- if(DETECTORHASH)
+ if (DETECTORHASH)
{
DETECTORHASH_LOCK;
kh_destroy(detector, DETECTORHASH);
khiter_t k;
int ret = 0;
- if(unlikely(SYMBOLHASH == 0))
+ if (unlikely(SYMBOLHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(psymbol == NULL))
+ if (unlikely(psymbol == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
SYMBOLHASH_LOCK;
k = kh_get(symbol, SYMBOLHASH, (uint32_t)ptr);
- if(k == kh_end(SYMBOLHASH)) // there is no entry for key
+ if (k == kh_end(SYMBOLHASH)) // there is no entry for key
{
ret = 0;
}
khiter_t k;
int rethash, ret = 0;
- if(unlikely(SYMBOLHASH == 0))
+ if (unlikely(SYMBOLHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(str == NULL))
+ if (unlikely(str == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
SYMBOLHASH_LOCK;
k = kh_put(symbol, SYMBOLHASH, (uint32_t)ptr, &rethash);
- if(likely(rethash != 0)) // succeed to add in hash table
+ if (likely(rethash != 0)) // succeed to add in hash table
{
char* tlast = (char*)malloc(strlen);
- if(likely(tlast != NULL))
+ if (likely(tlast != NULL))
{
memcpy(tlast, str, strlen);
kh_value(SYMBOLHASH, k) = tlast;
size_t memsize;
uint64_t meminfo;
- if(unlikely(MEMORYHASH == 0))
+ if (unlikely(MEMORYHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
MEMORYHASH_LOCK;
k = kh_put(allocmap, MEMORYHASH, (uint32_t)ptr, &rethash);
- if(likely(rethash != 0)) // succeed to add in hash table
+ if (likely(rethash != 0)) // succeed to add in hash table
{
kh_value(MEMORYHASH, k) = MAKE_MEMINFO(caller, type, size);
update_heap_memory_size(true, size);
// update memory info
meminfo = kh_value(MEMORYHASH, k);
memsize = GET_MEMSIZE(meminfo);
- if(memsize == size)
+ if (memsize == size)
{
kh_value(MEMORYHASH, k) = MAKE_MEMINFO(caller, type, size);
}
uint32_t size;
uint64_t meminfo;
- if(unlikely(MEMORYHASH == 0))
+ if (unlikely(MEMORYHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
MEMORYHASH_LOCK;
k = kh_get(allocmap, MEMORYHASH, (uint32_t)ptr);
- if(likely(k != kh_end(MEMORYHASH)))
+ if (likely(k != kh_end(MEMORYHASH)))
{ // there is entry in hash table
meminfo = kh_value(MEMORYHASH, k);
- if(unlikely(type != GET_MEMTYPE(meminfo)))
+ if (unlikely(type != GET_MEMTYPE(meminfo)))
{
ret = -1;
}
else
{
size = GET_MEMSIZE(meminfo);
- if(caller != NULL)
+ if (caller != NULL)
*caller = GET_MEMCALLER(meminfo);
update_heap_memory_size(false, size);
kh_del(allocmap, MEMORYHASH, k);
}
/***********************************************************
- * object hash related functions
+ * uiobject hash related functions
***********************************************************/
// return 0 if there is no entry in hash
// return 1 if there is entry in hash
// return negative value if error occurred
-int find_object_hash(void* ptr, char** type, char** classname)
+int find_uiobject_hash(void* ptr, char** type, char** classname)
{
khiter_t k;
int ret = 0;
- if(unlikely(OBJECTHASH == 0))
+ if (unlikely(UIOBJECTHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(type == NULL))
+ if (unlikely(type == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(classname == NULL))
+ if (unlikely(classname == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
- OBJECTHASH_LOCK;
- k = kh_get(object, OBJECTHASH, (uint32_t)ptr);
- if(unlikely(k == kh_end(OBJECTHASH))) // there is no entry for key
+ UIOBJECTHASH_LOCK;
+ k = kh_get(uiobject, UIOBJECTHASH, (uint32_t)ptr);
+ if (unlikely(k == kh_end(UIOBJECTHASH))) // there is no entry for key
{
ret = 0;
}
else
{
- *classname = kh_value(OBJECTHASH, k)->name;
- *type = kh_value(OBJECTHASH, k)->type;
+ *classname = kh_value(UIOBJECTHASH, k)->name;
+ *type = kh_value(UIOBJECTHASH, k)->type;
ret = 1;
}
- OBJECTHASH_UNLOCK;
+ UIOBJECTHASH_UNLOCK;
probeBlockEnd();
return ret;
}
// return 0 if succeed
// return 1 if there is no entry in hash
// return negative value if other error occurred
-int add_object_hash_class(void* ptr, const char* classname)
+int add_uiobject_hash_class(void* ptr, const char* classname)
{
int str_len;
khiter_t k;
int rethash, ret = 0;
- if(unlikely(OBJECTHASH == 0))
+ if (unlikely(UIOBJECTHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(classname == NULL))
+ if (unlikely(classname == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
str_len = strlen(classname) + 1;
- OBJECTHASH_LOCK;
- k = kh_put(object, OBJECTHASH, (uint32_t)ptr, &rethash);
- if(likely(rethash == 0)) // entry is already in hash table
+ UIOBJECTHASH_LOCK;
+ k = kh_put(uiobject, UIOBJECTHASH, (uint32_t)ptr, &rethash);
+ if (likely(rethash == 0)) // entry is already in hash table
{
- if(likely(kh_value(OBJECTHASH, k) != NULL))
+ if (likely(kh_value(UIOBJECTHASH, k) != NULL))
{
- if(kh_value(OBJECTHASH, k)->name == NULL)
+ if (kh_value(UIOBJECTHASH, k)->name == NULL)
{
char* tlast = (char*)malloc(str_len);
- if(likely(tlast != NULL))
+ if (likely(tlast != NULL))
{
memcpy(tlast, classname, str_len);
- kh_value(OBJECTHASH, k)->name = tlast;
+ kh_value(UIOBJECTHASH, k)->name = tlast;
}
else
{
- kh_value(OBJECTHASH, k)->name = NULL;
+ kh_value(UIOBJECTHASH, k)->name = NULL;
ret = ERR_OUTOFMEMORY; // out of memory
}
}
else // error
ret = 1; // there is no entry
- OBJECTHASH_UNLOCK;
+ UIOBJECTHASH_UNLOCK;
probeBlockEnd();
return ret;
}
// return 0 if succeed
// return 1 if there is already exist in hash
// return negative value if other error occurred
-int add_object_hash_type(void* ptr, const char* type)
+int add_uiobject_hash_type(void* ptr, const char* type)
{
int str_len;
khiter_t k;
int rethash, ret = 0;
- if(unlikely(OBJECTHASH == 0))
+ if (unlikely(UIOBJECTHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(type == NULL))
+ if (unlikely(type == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
str_len = strlen(type) + 1;
- OBJECTHASH_LOCK;
- k = kh_put(object, OBJECTHASH, (uint32_t)ptr, &rethash);
- if(likely(rethash != 0)) // succeed to add in hash table
+ UIOBJECTHASH_LOCK;
+ k = kh_put(uiobject, UIOBJECTHASH, (uint32_t)ptr, &rethash);
+ if (likely(rethash != 0)) // succeed to add in hash table
{
char* tlast;
- _objectinfo* newentry;
+ _uiobjectinfo* newentry;
- newentry = (_objectinfo*)calloc(1, sizeof(_objectinfo));
- if(likely(newentry != NULL))
+ newentry = (_uiobjectinfo*)calloc(1, sizeof(_uiobjectinfo));
+ if (likely(newentry != NULL))
{
- kh_value(OBJECTHASH, k) = newentry;
+ kh_value(UIOBJECTHASH, k) = newentry;
tlast = (char*)malloc(str_len);
- if(likely(tlast != NULL))
+ if (likely(tlast != NULL))
{
memcpy(tlast, type, str_len);
- kh_value(OBJECTHASH, k)->type = tlast;
+ kh_value(UIOBJECTHASH, k)->type = tlast;
}
else
{
- kh_value(OBJECTHASH, k)->type = NULL;
+ kh_value(UIOBJECTHASH, k)->type = NULL;
ret = ERR_OUTOFMEMORY;
}
}
else
{
- kh_del(object, OBJECTHASH, k);
+ kh_del(uiobject, UIOBJECTHASH, k);
ret = ERR_OUTOFMEMORY;
}
}
else
ret = 1;
+ UIOBJECTHASH_UNLOCK;
+ probeBlockEnd();
+ return ret;
+}
+
+// return 0 if succeed
+// return 1 if key is not in hash table
+// return negative value if other error occurred
+int del_uiobject_hash(void* ptr)
+{
+ khiter_t k;
+ _uiobjectinfo* val;
+ int ret = 0;
+
+ if (unlikely(UIOBJECTHASH == 0))
+ return ERR_NOTINITIALIZED;
+
+ if (unlikely(ptr == NULL))
+ return ERR_WRONGPARAMETER;
+
+ probeBlockStart();
+ UIOBJECTHASH_LOCK;
+ k = kh_get(uiobject, UIOBJECTHASH, (uint32_t)ptr);
+ if (likely(k != kh_end(UIOBJECTHASH))) // there is entry in hash table
+ {
+ val = kh_value(UIOBJECTHASH, k);
+ kh_del(uiobject, UIOBJECTHASH, k);
+ if (likely(val->type != NULL)) free(val->type);
+ if (likely(val->name != NULL)) free(val->name);
+ free(val);
+ }
+ else
+ {
+ ret = 1;
+ }
+ UIOBJECTHASH_UNLOCK;
+ probeBlockEnd();
+
+ return ret;
+}
+
+/***********************************************************
+ * object hash related functions
+ ***********************************************************/
+// return 0 if there is no entry in hash
+// return 1 if there is entry in hash
+// return negative value if error occurred
+int find_object_hash(void* ptr, unsigned short *caller)
+{
+ khiter_t k;
+ int ret = 0;
+
+ if (unlikely(OBJECTHASH == 0))
+ return ERR_NOTINITIALIZED;
+
+ if (unlikely(ptr == NULL))
+ return ERR_WRONGPARAMETER;
+
+ if (unlikely(caller == NULL))
+ return ERR_WRONGPARAMETER;
+
+ probeBlockStart();
+
+ OBJECTHASH_LOCK;
+ k = kh_get(object, OBJECTHASH, (uint32_t)ptr);
+ if (unlikely(k == kh_end(OBJECTHASH))) // there is no entry for key
+ {
+ ret = 0;
+ }
+ else
+ {
+ *caller = kh_value(OBJECTHASH, k);
+ ret = 1;
+ }
+ OBJECTHASH_UNLOCK;
+ probeBlockEnd();
+ return ret;
+}
+
+// return 0 if succeed
+// return 1 if there is no entry in hash
+// return negative value if other error occurred
+int add_object_hash(void* ptr, unsigned short caller)
+{
+ khiter_t k;
+ int rethash, ret = 0;
+
+ if (unlikely(OBJECTHASH == 0))
+ return ERR_NOTINITIALIZED;
+
+ if (unlikely(ptr == NULL))
+ return ERR_WRONGPARAMETER;
+
+ probeBlockStart();
+
+ OBJECTHASH_LOCK;
+ k = kh_put(object, OBJECTHASH, (uint32_t)ptr, &rethash);
+ if (likely(rethash != 0)) // entry is already in hash table
+ {
+ kh_value(OBJECTHASH, k) = caller;
+ }
+ else
+ {
+ // TODO : error handling
+ ret = 1;
+ }
+
OBJECTHASH_UNLOCK;
probeBlockEnd();
return ret;
// return 0 if succeed
// return 1 if key is not in hash table
// return negative value if other error occurred
-int del_object_hash(void* ptr)
+int del_object_hash(void* ptr, unsigned short *caller)
{
khiter_t k;
- _objectinfo* val;
int ret = 0;
- if(unlikely(OBJECTHASH == 0))
+ if (unlikely(OBJECTHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
+ return ERR_WRONGPARAMETER;
+
+ if (unlikely(caller == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
+
OBJECTHASH_LOCK;
k = kh_get(object, OBJECTHASH, (uint32_t)ptr);
- if(likely(k != kh_end(OBJECTHASH))) // there is entry in hash table
+ if (likely(k != kh_end(OBJECTHASH))) // there is entry in hash table
{
- val = kh_value(OBJECTHASH, k);
+ *caller = kh_value(OBJECTHASH, k);
kh_del(object, OBJECTHASH, k);
- if(likely(val->type != NULL)) free(val->type);
- if(likely(val->name != NULL)) free(val->name);
- free(val);
}
else
{
khiter_t k;
int rethash, ret = 0;
- if(unlikely(DETECTORHASH == 0))
+ if (unlikely(DETECTORHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
- if(unlikely(listener == NULL))
+ if (unlikely(listener == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
DETECTORHASH_LOCK;
k = kh_put(detector, DETECTORHASH, (uint32_t)ptr, &rethash);
- if(likely(rethash != 0)) // succeed to add in hash table
+ if (likely(rethash != 0)) // succeed to add in hash table
{
kh_value(DETECTORHASH, k) = listener;
}
khiter_t k;
int ret = 0;
- if(unlikely(DETECTORHASH == 0))
+ if (unlikely(DETECTORHASH == 0))
return ERR_NOTINITIALIZED;
- if(unlikely(ptr == NULL))
+ if (unlikely(ptr == NULL))
return ERR_WRONGPARAMETER;
probeBlockStart();
DETECTORHASH_LOCK;
k = kh_get(detector, DETECTORHASH, (uint32_t)ptr);
- if(likely(k != kh_end(DETECTORHASH))) // there is entry in hash table
+ if (likely(k != kh_end(DETECTORHASH))) // there is entry in hash table
{
kh_del(detector, DETECTORHASH, k);
}
element_t* res;
int keylen;
- if(unlikely(key == NULL))
+ if (unlikely(key == NULL))
return NULL;
keylen = strlen(key);
res = gsymbol_list;
while(res != NULL)
{
- if(keylen == res->keylen && (strcmp(key, res->keystr) == 0))
+ if (keylen == res->keylen && (strcmp(key, res->keystr) == 0))
break;
res = res->next;
}
element_t* elm;
int ret = 0;
- if(unlikely(key == NULL || data == NULL))
+ if (unlikely(key == NULL || data == NULL))
return 0;
pthread_mutex_lock(&glist_mutex);
elm = find_element(key);
- if(elm == NULL)
+ if (elm == NULL)
{
elm = (element_t*)malloc(sizeof(element_t));
- if(likely(elm != NULL))
+ if (likely(elm != NULL))
{
elm->keylen = strlen(key);
elm->keystr = (char*)malloc(elm->keylen + 1);
- if(likely(elm->keystr != NULL))
+ if (likely(elm->keystr != NULL))
{
strcpy(elm->keystr, key);
elm->dataptr = data;
elm->next = gsymbol_list;
elm->prev = NULL;
- if(gsymbol_list)
+ if (gsymbol_list)
gsymbol_list->prev = elm;
gsymbol_list = elm;
ret = 1;
pthread_mutex_lock(&glist_mutex);
elm = find_element(key);
- if(elm != NULL)
+ if (elm != NULL)
{
- if(elm->prev)
+ if (elm->prev)
elm->prev->next = elm->next;
- if(elm->next)
+ if (elm->next)
elm->next->prev = elm->prev;
- if(gsymbol_list == elm)
+ if (gsymbol_list == elm)
gsymbol_list = gsymbol_list->next;
}
pthread_mutex_unlock(&glist_mutex);
- if(elm != NULL)
+ if (elm != NULL)
{
free(elm->dataptr);
free(elm->keystr);
elm = find_element(key);
pthread_mutex_unlock(&glist_mutex);
- if(elm)
+ if (elm)
return elm->dataptr;
else
return NULL;
BUF_PTR = pack_int64(BUF_PTR, 0); \
} else { \
char *type = NULL, *name = NULL; \
- if (find_object_hash((void*)(control), \
+ if (find_uiobject_hash((void*)(control), \
&type, &name) == 1) { \
BUF_PTR = pack_string(BUF_PTR, type); \
BUF_PTR = pack_string(BUF_PTR, name); \
BUF_PTR = pack_int64(BUF_PTR, 0); \
} else { \
char *type = NULL, *name = NULL; \
- if (find_object_hash((void*)(pform), &type, &name) == 1) { \
+ if (find_uiobject_hash((void*)(pform), &type, &name) == 1) { \
BUF_PTR = pack_string(BUF_PTR, name); \
} else { \
BUF_PTR = pack_string(BUF_PTR, ""); \
BUF_PTR = pack_int64(BUF_PTR, 0); \
} else { \
char *type = NULL, *name = NULL; \
- if (find_object_hash((void*)(ppanel), &type, &name) == 1) { \
+ if (find_uiobject_hash((void*)(ppanel), &type, &name) == 1) { \
BUF_PTR = pack_string(BUF_PTR, name); \
} else { \
BUF_PTR = pack_string(BUF_PTR, ""); \
#define MEMORYHASH_LOCK pthread_mutex_lock(&(_hashinfo.memHashMutex))
#define MEMORYHASH_UNLOCK pthread_mutex_unlock(&(_hashinfo.memHashMutex))
+#define UIOBJECTHASH _hashinfo.uiobjHash
+#define UIOBJECTHASH_LOCK pthread_mutex_lock(&(_hashinfo.uiobjHashMutex))
+#define UIOBJECTHASH_UNLOCK pthread_mutex_unlock(&(_hashinfo.uiobjHashMutex))
+
#define OBJECTHASH _hashinfo.objHash
#define OBJECTHASH_LOCK pthread_mutex_lock(&(_hashinfo.objHashMutex))
#define OBJECTHASH_UNLOCK pthread_mutex_unlock(&(_hashinfo.objHashMutex))
#define MAKE_MEMINFO(caller, type, size) \
(((uint64_t)caller << 48) | ((uint64_t)type << 32) | ((uint64_t)size))
+#define OBJECT_INTERNAL 0x01
+#define OBJECT_EXTERNAL 0x02
+
typedef struct
{
char* type;
char* name;
-} _objectinfo;
+} _uiobjectinfo;
// khash table function definition
KHASH_MAP_INIT_INT(symbol, char*)
KHASH_MAP_INIT_INT(allocmap, uint64_t)
-KHASH_MAP_INIT_INT(object, _objectinfo*)
+KHASH_MAP_INIT_INT(uiobject, _uiobjectinfo*)
+
+KHASH_MAP_INIT_INT(object, unsigned short)
KHASH_MAP_INIT_INT(detector, void*)
pthread_mutex_t symHashMutex;
khash_t(allocmap)* memHash;
pthread_mutex_t memHashMutex;
+ khash_t(uiobject)* uiobjHash;
+ pthread_mutex_t uiobjHashMutex;
khash_t(object)* objHash;
pthread_mutex_t objHashMutex;
khash_t(detector)* dttHash;
int add_memory_hash(void* ptr, size_t size, unsigned short type, unsigned short caller);
int del_memory_hash(void* ptr, unsigned short type, unsigned short* caller);
-int find_object_hash(void* ptr, char** type, char** classname);
-int add_object_hash_class(void* ptr, const char* classname);
-int add_object_hash_type(void* ptr, const char* type);
-int del_object_hash(void* ptr);
+int find_uiobject_hash(void* ptr, char** type, char** classname);
+int add_uiobject_hash_class(void* ptr, const char* classname);
+int add_uiobject_hash_type(void* ptr, const char* type);
+int del_uiobject_hash(void* ptr);
+
+int find_object_hash(void* ptr, unsigned short *caller);
+int add_object_hash(void* ptr, unsigned short caller);
+int del_object_hash(void* ptr, unsigned short *caller);
int add_detector_hash(void* ptr, void* listener);
int del_detector_hash(void* ptr);
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui7ControlC2Ev, LIBOSP_UIFW, control_controlp);
probeBlockStart();
- add_object_hash_type((void*)this, "Control");
+ add_uiobject_hash_type((void*)this, "Control");
probeBlockEnd();
(this->*control_controlp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui7ControlD2Ev, LIBOSP_UIFW, control__controlvoidp);
probeBlockStart();
- del_object_hash(static_cast<void*>(this));
+ del_uiobject_hash(static_cast<void*>(this));
probeBlockEnd();
(this->*control__controlvoidp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui17CustomControlBaseC2Ev, LIBOSP_UIFW, customcontrolbase_customcontrolbasep);
probeBlockStart();
- add_object_hash_type((void*)this, "CustomControlBase");
+ add_uiobject_hash_type((void*)this, "CustomControlBase");
probeBlockEnd();
(this->*customcontrolbase_customcontrolbasep)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui9ContainerC2Ev, LIBOSP_UIFW, container_containerp);
probeBlockStart();
- add_object_hash_type((void*)this, "Container");
+ add_uiobject_hash_type((void*)this, "Container");
probeBlockEnd();
(this->*container_containerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui6WindowC2Ev, LIBOSP_UIFW, window_windowp);
probeBlockStart();
- add_object_hash_type((void*)this, "Window");
+ add_uiobject_hash_type((void*)this, "Window");
probeBlockEnd();
(this->*window_windowp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls9AnimationC2Ev, LIBOSP_UIFW, animation_animationp);
probeBlockStart();
- add_object_hash_type((void*)this, "Animation");
+ add_uiobject_hash_type((void*)this, "Animation");
probeBlockEnd();
(this->*animation_animationp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6ButtonC2Ev, LIBOSP_UIFW, button_buttonp);
probeBlockStart();
- add_object_hash_type((void*)this, "Button");
+ add_uiobject_hash_type((void*)this, "Button");
probeBlockEnd();
(this->*button_buttonp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls11CheckButtonC2Ev, LIBOSP_UIFW, checkbutton_checkbuttonp);
probeBlockStart();
- add_object_hash_type((void*)this, "CheckButton");
+ add_uiobject_hash_type((void*)this, "CheckButton");
probeBlockEnd();
(this->*checkbutton_checkbuttonp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls11ColorPickerC2Ev, LIBOSP_UIFW, colorpicker_colorpickerp);
probeBlockStart();
- add_object_hash_type((void*)this, "ColorPicker");
+ add_uiobject_hash_type((void*)this, "ColorPicker");
probeBlockEnd();
(this->*colorpicker_colorpickerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10CustomListC2Ev, LIBOSP_UIFW, customlist_customlistp);
probeBlockStart();
- add_object_hash_type((void*)this, "CustomList");
+ add_uiobject_hash_type((void*)this, "CustomList");
probeBlockEnd();
(this->*customlist_customlistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8EditAreaC2Ev, LIBOSP_UIFW, editarea_editareap);
probeBlockStart();
- add_object_hash_type((void*)this, "EditArea");
+ add_uiobject_hash_type((void*)this, "EditArea");
probeBlockEnd();
(this->*editarea_editareap)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8EditDateC2Ev, LIBOSP_UIFW, editdate_editdatep);
probeBlockStart();
- add_object_hash_type((void*)this, "EditDate");
+ add_uiobject_hash_type((void*)this, "EditDate");
probeBlockEnd();
(this->*editdate_editdatep)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls9EditFieldC2Ev, LIBOSP_UIFW, editfield_editfieldp);
probeBlockStart();
- add_object_hash_type((void*)this, "EditField");
+ add_uiobject_hash_type((void*)this, "EditField");
probeBlockEnd();
(this->*editfield_editfieldp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8EditTimeC2Ev, LIBOSP_UIFW, edittime_edittimep);
probeBlockStart();
- add_object_hash_type((void*)this, "EditTime");
+ add_uiobject_hash_type((void*)this, "EditTime");
probeBlockEnd();
(this->*edittime_edittimep)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls18ExpandableEditAreaC2Ev, LIBOSP_UIFW, expandableeditarea_expandableeditareap);
probeBlockStart();
- add_object_hash_type((void*)this, "ExpandableEditArea");
+ add_uiobject_hash_type((void*)this, "ExpandableEditArea");
probeBlockEnd();
(this->*expandableeditarea_expandableeditareap)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls14ExpandableListC2Ev, LIBOSP_UIFW, expandablelist_expandablelistp);
probeBlockStart();
- add_object_hash_type((void*)this, "ExpandableList");
+ add_uiobject_hash_type((void*)this, "ExpandableList");
probeBlockEnd();
(this->*expandablelist_expandablelistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6FooterC2Ev, LIBOSP_UIFW, footer_footerp);
probeBlockStart();
- add_object_hash_type((void*)this, "Footer");
+ add_uiobject_hash_type((void*)this, "Footer");
probeBlockEnd();
(this->*footer_footerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls7GalleryC2Ev, LIBOSP_UIFW, gallery_galleryp);
probeBlockStart();
- add_object_hash_type((void*)this, "Gallery");
+ add_uiobject_hash_type((void*)this, "Gallery");
probeBlockEnd();
(this->*gallery_galleryp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls11GroupedListC2Ev, LIBOSP_UIFW, groupedlist_groupedlistp);
probeBlockStart();
- add_object_hash_type((void*)this, "GroupedList");
+ add_uiobject_hash_type((void*)this, "GroupedList");
probeBlockEnd();
(this->*groupedlist_groupedlistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls15GroupedListViewC2Ev, LIBOSP_UIFW, groupedlistview_groupedlistviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "GroupedListView");
+ add_uiobject_hash_type((void*)this, "GroupedListView");
probeBlockEnd();
(this->*groupedlistview_groupedlistviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6HeaderC2Ev, LIBOSP_UIFW, header_headerp);
probeBlockStart();
- add_object_hash_type((void*)this, "Header");
+ add_uiobject_hash_type((void*)this, "Header");
probeBlockEnd();
(this->*header_headerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8IconListC2Ev, LIBOSP_UIFW, iconlist_iconlistp);
probeBlockStart();
- add_object_hash_type((void*)this, "IconList");
+ add_uiobject_hash_type((void*)this, "IconList");
probeBlockEnd();
(this->*iconlist_iconlistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls12IconListViewC2Ev, LIBOSP_UIFW, iconlistview_iconlistviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "IconListView");
+ add_uiobject_hash_type((void*)this, "IconListView");
probeBlockEnd();
(this->*iconlistview_iconlistviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls5LabelC2Ev, LIBOSP_UIFW, label_labelp);
probeBlockStart();
- add_object_hash_type((void*)this, "Label");
+ add_uiobject_hash_type((void*)this, "Label");
probeBlockEnd();
(this->*label_labelp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls4ListC2Ev, LIBOSP_UIFW, list_listp);
probeBlockStart();
- add_object_hash_type((void*)this, "List");
+ add_uiobject_hash_type((void*)this, "List");
probeBlockEnd();
(this->*list_listp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8ListViewC2Ev, LIBOSP_UIFW, listview_listviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "ListView");
+ add_uiobject_hash_type((void*)this, "ListView");
probeBlockEnd();
(this->*listview_listviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls8ProgressC2Ev, LIBOSP_UIFW, progress_progressp);
probeBlockStart();
- add_object_hash_type((void*)this, "Progress");
+ add_uiobject_hash_type((void*)this, "Progress");
probeBlockEnd();
(this->*progress_progressp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10RadioGroupC2Ev, LIBOSP_UIFW, radiogroup_radiogroupp);
probeBlockStart();
- add_object_hash_type((void*)this, "RadioGroup");
+ add_uiobject_hash_type((void*)this, "RadioGroup");
probeBlockEnd();
(this->*radiogroup_radiogroupp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls9SearchBarC2Ev, LIBOSP_UIFW, searchbar_searchbarp);
probeBlockStart();
- add_object_hash_type((void*)this, "SearchBar");
+ add_uiobject_hash_type((void*)this, "SearchBar");
probeBlockEnd();
(this->*searchbar_searchbarp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls19SlidableGroupedListC2Ev, LIBOSP_UIFW, slidablegroupedlist_slidablegroupedlistp);
probeBlockStart();
- add_object_hash_type((void*)this, "SlidableGroupedList");
+ add_uiobject_hash_type((void*)this, "SlidableGroupedList");
probeBlockEnd();
(this->*slidablegroupedlist_slidablegroupedlistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls12SlidableListC2Ev, LIBOSP_UIFW, slidablelist_slidablelistp);
probeBlockStart();
- add_object_hash_type((void*)this, "SlidableList");
+ add_uiobject_hash_type((void*)this, "SlidableList");
probeBlockEnd();
(this->*slidablelist_slidablelistp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6SliderC2Ev, LIBOSP_UIFW, slider_sliderp);
probeBlockStart();
- add_object_hash_type((void*)this, "Slider");
+ add_uiobject_hash_type((void*)this, "Slider");
probeBlockEnd();
(this->*slider_sliderp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10SplitPanelC2Ev, LIBOSP_UIFW, splitpanel_splitpanelp);
probeBlockStart();
- add_object_hash_type((void*)this, "SplitPanel");
+ add_uiobject_hash_type((void*)this, "SplitPanel");
probeBlockEnd();
(this->*splitpanel_splitpanelp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls3TabC2Ev, LIBOSP_UIFW, tab_tabp);
probeBlockStart();
- add_object_hash_type((void*)this, "Tab");
+ add_uiobject_hash_type((void*)this, "Tab");
probeBlockEnd();
(this->*tab_tabp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6TabBarC2Ev, LIBOSP_UIFW, tabbar_tabbarp);
probeBlockStart();
- add_object_hash_type((void*)this, "TabBar");
+ add_uiobject_hash_type((void*)this, "TabBar");
probeBlockEnd();
(this->*tabbar_tabbarp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls7TextBoxC2Ev, LIBOSP_UIFW, textbox_textboxp);
probeBlockStart();
- add_object_hash_type((void*)this, "TextBox");
+ add_uiobject_hash_type((void*)this, "TextBox");
probeBlockEnd();
(this->*textbox_textboxp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls4FormC2Ev, LIBOSP_UIFW, form_formp);
probeBlockStart();
- add_object_hash_type((void*)this, "Form");
+ add_uiobject_hash_type((void*)this, "Form");
probeBlockEnd();
(this->*form_formp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls16GroupedTableViewC2Ev, LIBOSP_UIFW, groupedtableview_groupedtableviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "GroupedTableView");
+ add_uiobject_hash_type((void*)this, "GroupedTableView");
probeBlockEnd();
(this->*groupedtableview_groupedtableviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls5PanelC2Ev, LIBOSP_UIFW, panel_panelp);
probeBlockStart();
- add_object_hash_type((void*)this, "Panel");
+ add_uiobject_hash_type((void*)this, "Panel");
probeBlockEnd();
(this->*panel_panelp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls12OverlayPanelC2Ev, LIBOSP_UIFW, overlaypanel_overlaypanelp);
probeBlockStart();
- add_object_hash_type((void*)this, "OverlayPanel");
+ add_uiobject_hash_type((void*)this, "OverlayPanel");
probeBlockEnd();
(this->*overlaypanel_overlaypanelp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls11ScrollPanelC2Ev, LIBOSP_UIFW, scrollpanel_scrollpanelp);
probeBlockStart();
- add_object_hash_type((void*)this, "ScrollPanel");
+ add_uiobject_hash_type((void*)this, "ScrollPanel");
probeBlockEnd();
(this->*scrollpanel_scrollpanelp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls16SectionTableViewC2Ev, LIBOSP_UIFW, sectiontableview_sectiontableviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "SectionTableView");
+ add_uiobject_hash_type((void*)this, "SectionTableView");
probeBlockEnd();
(this->*sectiontableview_sectiontableviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls9TableViewC2Ev, LIBOSP_UIFW, tableview_tableviewp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableView");
+ add_uiobject_hash_type((void*)this, "TableView");
probeBlockEnd();
(this->*tableview_tableviewp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls17TableViewItemBaseC2Ev, LIBOSP_UIFW, tableviewitembase_tableviewitembasep);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewItemBase");
+ add_uiobject_hash_type((void*)this, "TableViewItemBase");
probeBlockEnd();
(this->*tableviewitembase_tableviewitembasep)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls20TableViewContextItemC2Ev, LIBOSP_UIFW, tableviewcontextitem_tableviewcontextitemp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewContextItem");
+ add_uiobject_hash_type((void*)this, "TableViewContextItem");
probeBlockEnd();
(this->*tableviewcontextitem_tableviewcontextitemp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls18TableViewGroupItemC2Ev, LIBOSP_UIFW, tableviewgroupitem_tableviewgroupitemp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewGroupItem");
+ add_uiobject_hash_type((void*)this, "TableViewGroupItem");
probeBlockEnd();
(this->*tableviewgroupitem_tableviewgroupitemp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls13TableViewItemC2Ev, LIBOSP_UIFW, tableviewitem_tableviewitemp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewItem");
+ add_uiobject_hash_type((void*)this, "TableViewItem");
probeBlockEnd();
(this->*tableviewitem_tableviewitemp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls24TableViewSimpleGroupItemC2Ev, LIBOSP_UIFW, tableviewsimplegroupitem_tableviewsimplegroupitemp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewSimpleGroupItem");
+ add_uiobject_hash_type((void*)this, "TableViewSimpleGroupItem");
probeBlockEnd();
(this->*tableviewsimplegroupitem_tableviewsimplegroupitemp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls19TableViewSimpleItemC2Ev, LIBOSP_UIFW, tableviewsimpleitem_tableviewsimpleitemp);
probeBlockStart();
- add_object_hash_type((void*)this, "TableViewSimpleItem");
+ add_uiobject_hash_type((void*)this, "TableViewSimpleItem");
probeBlockEnd();
(this->*tableviewsimpleitem_tableviewsimpleitemp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls11ContextMenuC2Ev, LIBOSP_UIFW, contextmenu_contextmenup);
probeBlockStart();
- add_object_hash_type((void*)this, "ContextMenu");
+ add_uiobject_hash_type((void*)this, "ContextMenu");
probeBlockEnd();
(this->*contextmenu_contextmenup)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10DatePickerC2Ev, LIBOSP_UIFW, datepicker_datepickerp);
probeBlockStart();
- add_object_hash_type((void*)this, "DatePicker");
+ add_uiobject_hash_type((void*)this, "DatePicker");
probeBlockEnd();
(this->*datepicker_datepickerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls14DateTimePickerC2Ev, LIBOSP_UIFW, datetimepicker_datetimepickerp);
probeBlockStart();
- add_object_hash_type((void*)this, "DateTimePicker");
+ add_uiobject_hash_type((void*)this, "DateTimePicker");
probeBlockEnd();
(this->*datetimepicker_datetimepickerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls5FrameC2Ev, LIBOSP_UIFW, frame_framep);
probeBlockStart();
- add_object_hash_type((void*)this, "Frame");
+ add_uiobject_hash_type((void*)this, "Frame");
probeBlockEnd();
(this->*frame_framep)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls6KeypadC2Ev, LIBOSP_UIFW, keypad_keypadp);
probeBlockStart();
- add_object_hash_type((void*)this, "Keypad");
+ add_uiobject_hash_type((void*)this, "Keypad");
probeBlockEnd();
(this->*keypad_keypadp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10MessageBoxC2Ev, LIBOSP_UIFW, messagebox_messageboxp);
probeBlockStart();
- add_object_hash_type((void*)this, "MessageBox");
+ add_uiobject_hash_type((void*)this, "MessageBox");
probeBlockEnd();
(this->*messagebox_messageboxp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10OptionMenuC2Ev, LIBOSP_UIFW, optionmenu_optionmenup);
probeBlockStart();
- add_object_hash_type((void*)this, "OptionMenu");
+ add_uiobject_hash_type((void*)this, "OptionMenu");
probeBlockEnd();
(this->*optionmenu_optionmenup)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls5PopupC2Ev, LIBOSP_UIFW, popup_popupp);
probeBlockStart();
- add_object_hash_type((void*)this, "Popup");
+ add_uiobject_hash_type((void*)this, "Popup");
probeBlockEnd();
(this->*popup_popupp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen2Ui8Controls10TimePickerC2Ev, LIBOSP_UIFW, timepicker_timepickerp);
probeBlockStart();
- add_object_hash_type((void*)this, "TimePicker");
+ add_uiobject_hash_type((void*)this, "TimePicker");
probeBlockEnd();
(this->*timepicker_timepickerp)();
GET_REAL_FUNC_TIZEN(_ZN5Tizen3Web8Controls3WebC2Ev, LIBOSP_WEB, web_webp);
probeBlockStart();
- add_object_hash_type((void*)this, "Web");
+ add_uiobject_hash_type((void*)this, "Web");
probeBlockEnd();
(this->*web_webp)();
GET_REAL_FUNC_TIZEN(_ZNK5Tizen2Ui7Control13IsInTouchModeEv, LIBOSP_UIFW, control_isintouchmodep);
probeBlockStart();
- add_object_hash_class((void*)(this), typeid(*this).name());
+ add_uiobject_hash_class((void*)(this), typeid(*this).name());
probeBlockEnd();
return (this->*control_isintouchmodep)();
if(unlikely(IsRegisteredFrameAnimatorEventListener == false))
{
char *type = NULL, *classname = NULL;
- if(likely(find_object_hash((void*)this, &type, &classname) == 1)) // there is entry in object hash
+ if (likely(find_uiobject_hash((void*)this, &type, &classname) == 1)) // there is entry in object hash
{
- if(strcmp(type, "Frame") == 0)
+ if (strcmp(type, "Frame") == 0)
{
FrameAnimator* fa = ((Frame*)this)->GetFrameAnimator();
- if(fa != NULL)
+ if (fa != NULL)
{
fa->AddFrameAnimatorEventListener(GetFrameAnimatorEventListener());
IsRegisteredFrameAnimatorEventListener = true;
if(unlikely(IsRegisteredFrameAnimatorEventListener == false))
{
char *type = NULL, *classname = NULL;
- if(likely(find_object_hash((void*)this, &type, &classname) == 1)) // there is entry in object hash
+ if (likely(find_uiobject_hash((void*)this, &type, &classname) == 1)) // there is entry in object hash
{
- if(strcmp(type, "Frame") == 0)
+ if (strcmp(type, "Frame") == 0)
{
FrameAnimator* fa = ((Frame*)this)->GetFrameAnimator();
- if(fa != NULL)
+ if (fa != NULL)
{
fa->AddFrameAnimatorEventListener(GetFrameAnimatorEventListener());
IsRegisteredFrameAnimatorEventListener = true;
PACK_COMMON_END('x', ret, 0, 0);
PACK_UICONTROL(this);
PACK_UICONTROL(control);
-
PRE_PROBEBLOCK_END();
ret = (this->*container_removecontrolp)(control);
#include "daprobe.h"
#include "probeinfo.h"
#include "dahelper.h"
+#include "dacollection.h"
#include "binproto.h"
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Constructp)(filePath, openMode, createParentDirectories);
- if(postBlockBegin(blockresult)) {
+ if (gProbeBlockCount == 0 && blockresult)
+ {
+ add_object_hash((void*)this, OBJECT_EXTERNAL);
+ }
+
+ if (postBlockBegin(blockresult)) {
char buffer[PATH_MAX];
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp_path,filePath.GetPointer());
WcharToChar(temp_mode,openMode.GetPointer());
FileAttributes attr;
long long size = 0L;
- if(!Constructp) {
+ if (!Constructp) {
probeBlockStart();
void *tmpPtr = dlsym(RTLD_NEXT,
"_ZN5Tizen2Io4File9ConstructERKNS_4Base6StringES5_");
- if(tmpPtr == NULL || dlerror() != NULL) {
+ if (tmpPtr == NULL || dlerror() != NULL) {
perror("dlsym failed : Tizen::Io::File::Construct");
exit(0);
}
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Constructp)(filePath, openMode);
- if(postBlockBegin(blockresult)) {
+ if (gProbeBlockCount == 0 && blockresult)
+ {
+ add_object_hash((void*)this, OBJECT_EXTERNAL);
+ }
+
+ if (postBlockBegin(blockresult)) {
char buffer[PATH_MAX];
WcharToChar(temp_path,filePath.GetPointer());
// Comment this because of fault during Internet application profiling
// (it closes unexpectedly) but for DATizenTestApp it is ok
// There is the same problem at File::~File(void)
- //if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ //if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
// size = attr.GetFileSize();
PREPARE_LOCAL_BUF();
FileAttributes attr;
long long size = 0L;
- if(!Constructp) {
+ if (!Constructp) {
probeBlockStart();
void *tmpPtr = dlsym(RTLD_NEXT,
"_ZN5Tizen2Io4File9ConstructERKNS_4Base6StringEPKc");
- if(tmpPtr == NULL || dlerror() != NULL) {
+ if (tmpPtr == NULL || dlerror() != NULL) {
perror("dlsym failed : Tizen::Io::File::Construct");
exit(0);
}
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Constructp)(filePath, pOpenMode);
- if(postBlockBegin(blockresult)) {
+ if (gProbeBlockCount == 0 && blockresult)
+ {
+ add_object_hash((void*)this, OBJECT_EXTERNAL);
+ }
+
+ if (postBlockBegin(blockresult)) {
char buffer[PATH_MAX];
WcharToChar(temp,filePath.GetPointer());
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
PREPARE_LOCAL_BUF();
FileAttributes attr;
long long size = 0L;
- if(!Constructp) {
+ if (!Constructp) {
probeBlockStart();
void *tmpPtr = dlsym(RTLD_NEXT,
"_ZN5Tizen2Io4File9ConstructERKNS_4Base6StringEPKcRKNS2_10ByteBufferE");
- if(tmpPtr == NULL || dlerror() != NULL) {
+ if (tmpPtr == NULL || dlerror() != NULL) {
perror("dlsym failed : Tizen::Io::File::Construct");
exit(0);
}
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Constructp)(filePath, pOpenMode, secretKey);
- if(postBlockBegin(blockresult)) {
+ if (gProbeBlockCount == 0 && blockresult)
+ {
+ add_object_hash((void*)this, OBJECT_EXTERNAL);
+ }
+
+ if (postBlockBegin(blockresult)) {
WcharToChar(temp,filePath.GetPointer());
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
PREPARE_LOCAL_BUF();
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Flushp)();
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
WcharToChar(temp,this->GetName().GetPointer());
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
PREPARE_LOCAL_BUF();
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*GetNamep)();
result res = GetLastResult();
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
WcharToChar(temp,ret.GetPointer());
if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
ret = (this->*Readp)(buffer);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
nRead = buffer.GetLength();
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
ret = (this->*Readp)(buffer);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
buffer.GetInt(nRead);
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
nRead = Tell();
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
ret = (this->*Readp)(buffer, length);
result res = GetLastResult();
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
nRead = Tell() - nRead;
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Seekp)(position, offset);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
- if(FILESEEKPOSITION_BEGIN == position)
+ if (FILESEEKPOSITION_BEGIN == position)
strcpy(temp_pos, "FILESEEKPOSITION_BEGIN");
- else if(FILESEEKPOSITION_CURRENT == position)
+ else if (FILESEEKPOSITION_CURRENT == position)
strcpy(temp_pos, "FILESEEKPOSITION_CURRENT");
- else if(FILESEEKPOSITION_END == position)
+ else if (FILESEEKPOSITION_END == position)
strcpy(temp_pos, "FILESEEKPOSITION_END");
else
sprintf(temp_pos, "%d", position);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Tellp)();
result res = GetLastResult();
- if(postBlockBegin(blockresult)) {
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (postBlockBegin(blockresult)) {
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp,this->GetName().GetPointer());
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
preBlockEnd();
}
ret = (this->*Truncatep)(length);
- if(postBlockBegin(blockresult)) {
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (postBlockBegin(blockresult)) {
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp,this->GetName().GetPointer());
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
nWritten = Tell();
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
ret = (this->*Writep)(buffer, length);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp, this->GetName().GetPointer());
nWritten = Tell() - nWritten;
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
nWritten = Tell();
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp,this->GetName().GetPointer());
ret = (this->*Writep)(buffer);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp,this->GetName().GetPointer());
nWritten = Tell() - nWritten;
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
nWritten = Tell();
WcharToChar(temp_buf, buffer.GetPointer());
- if(E_SUCCESS == File::GetAttributes(this->GetName(), attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(), attr))
size = attr.GetFileSize();
WcharToChar(temp_path, this->GetName().GetPointer());
ret = (this->*Writep)(buffer);
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
setProbePoint(&probeInfo);
WcharToChar(temp_buf,buffer.GetPointer());
WcharToChar(temp_path,this->GetName().GetPointer());
nWritten = Tell() - nWritten;
- if(E_SUCCESS == File::GetAttributes(this->GetName(),attr))
+ if (E_SUCCESS == File::GetAttributes(this->GetName(),attr))
size = attr.GetFileSize();
nWritten = Tell() - nWritten;
void *tmpPtr;
// FileAttributes attr;
long long size = 0L;
+ unsigned short caller;
+ int ret;
if (!FileDp) {
probeBlockStart();
probeBlockEnd();
}
- if((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
+ if ((blockresult = preBlockBegin(CALLER_ADDRESS, bfiltering, _sopt)) != 0) {
setProbePoint(&probeInfo);
// error occur if File class was failed to contruct
// if (ret == E_SUCCESS &&
preBlockEnd();
}
+ if (gProbeBlockCount == 0)
+ {
+ probeBlockStart();
+ ret = del_object_hash((void*)this, &caller);
+ if (blockresult == 0 && ret == 0 && caller == OBJECT_EXTERNAL)
+ {
+ setProbePoint(&probeInfo);
+ blockresult = 2;
+ probingStart();
+ }
+ probeBlockEnd();
+ }
+
(this->*FileDp)();
- if(postBlockBegin(blockresult)) {
+ if (postBlockBegin(blockresult)) {
PREPARE_LOCAL_BUF();
PACK_COMMON_BEGIN(MSG_PROBE_RESOURCE,
result r;
Bitmap* pBitmap = NULL;
- if(unlikely(utilx_create_screen_shotp == NULL))
+ if (unlikely(utilx_create_screen_shotp == NULL))
{
void* lib_handle = dlopen(LIBUTILX, RTLD_LAZY);
- if(lib_handle == NULL) {
+ if (lib_handle == NULL) {
SetLastResult(ERR_DLOPEN);
return NULL;
}
utilx_create_screen_shotp = (utilx_create_screen_shot_type)dlsym(lib_handle, "utilx_create_screen_shot");
- if(utilx_create_screen_shotp == NULL || dlerror() != NULL) {
+ if (utilx_create_screen_shotp == NULL || dlerror() != NULL) {
SetLastResult(ERR_DLSYM);
return NULL;
}
}
- if(unlikely(utilx_release_screen_shotp == NULL))
+ if (unlikely(utilx_release_screen_shotp == NULL))
{
void* lib_handle = dlopen(LIBUTILX, RTLD_LAZY);
- if(lib_handle == NULL) {
+ if (lib_handle == NULL) {
SetLastResult(ERR_DLOPEN);
return NULL;
}
utilx_release_screen_shotp = (utilx_release_screen_shot_type)dlsym(lib_handle, "utilx_release_screen_shot");
- if(utilx_release_screen_shotp == NULL || dlerror() != NULL) {
+ if (utilx_release_screen_shotp == NULL || dlerror() != NULL) {
SetLastResult(ERR_DLSYM);
return NULL;
}
}
Display* pDpy = XOpenDisplay(NULL);
- if(pDpy == NULL)
+ if (pDpy == NULL)
{
SetLastResult(ERR_USER - 1);
return NULL;
int height = DisplayHeight(pDpy, DefaultScreen(pDpy));
void* pDump = utilx_create_screen_shotp(pDpy, width, height);
- if(likely(pDump != NULL))
+ if (likely(pDump != NULL))
{
ByteBuffer buffer;
r = buffer.Construct(static_cast<byte*>(pDump), 0, width*height*4, width*height*4);\
- if(likely(r == E_SUCCESS))
+ if (likely(r == E_SUCCESS))
{
Tizen::Graphics::Dimension dim(width, height);
Bitmap* pBitmap = new Bitmap();
- if(likely(pBitmap != NULL))
+ if (likely(pBitmap != NULL))
{
r = pBitmap->Construct(buffer, dim, BITMAP_PIXEL_FORMAT_ARGB8888);
- if(unlikely(r != E_SUCCESS))
+ if (unlikely(r != E_SUCCESS))
{
SetLastResult(r);
delete pBitmap;
Bitmap* pBitmap = NULL;
r = buffer.Construct(static_cast<byte*>(pDump), 0, width*height*4, width*height*4);
- if(likely(r == E_SUCCESS))
+ if (likely(r == E_SUCCESS))
{
Tizen::Graphics::Dimension dim(width, height);
pBitmap = new Bitmap();
- if(likely(pBitmap != NULL))
+ if (likely(pBitmap != NULL))
{
r = pBitmap->Construct(buffer, dim, BITMAP_PIXEL_FORMAT_ARGB8888);
- if(unlikely(r != E_SUCCESS))
+ if (unlikely(r != E_SUCCESS))
{
SetLastResult(r);
delete pBitmap;
probeBlockStart();
capbuf = captureScreenShotX(&width, &height);
- if(capbuf != NULL)
+ if (capbuf != NULL)
{
bitmap = getBitmapFromBuffer((void*)capbuf, width, height);
- if(bitmap != NULL)
+ if (bitmap != NULL)
{
String dstPath;
setProbePoint(&probeInfo);
dstPath.Format(MAX_PATH_LENGTH, L"/tmp/da/%d.jpg", probeInfo.eventIndex);
img.Construct();
r = img.EncodeToFile(*bitmap, IMG_FORMAT_JPG, dstPath, true);
- if(r == E_SUCCESS)
+ if (r == E_SUCCESS)
{
INIT_LOG;
APPEND_LOG_BASIC_NAME(LC_SNAPSHOT, "captureScreen");
probeBlockStart();
{
char *type, *classname;
- if(find_object_hash((void*)this, &type, &classname) == 1)
+ if (find_uiobject_hash((void*)this, &type, &classname) == 1)
{
- if(strcmp(type, "Panel") == 0 || strcmp(type, "OverlayPanel") == 0 || strcmp(type, "ScrollPanel") == 0)
+ if (strcmp(type, "Panel") == 0 || strcmp(type, "OverlayPanel") == 0 || strcmp(type, "ScrollPanel") == 0)
{
SCREENSHOT_SET();
// SCREENSHOT_DONE();
#include <FUi.h>
#include "daprobe.h"
-#include "dacollection.h" // for find_object_hash
+#include "dacollection.h" // for find_uiobject_hash
#include "dahelper.h" // for captureScreen
#include "tizen_probe.h"
{
SceneManager* scenemanager = SceneManager::GetInstance();
- if(scenemanager->GetCurrentSceneId() == currentSceneId)
+ if (scenemanager->GetCurrentSceneId() == currentSceneId)
{
- if(isOptionEnabled(OPT_UI))
+ if (isOptionEnabled(OPT_UI))
{
probeInfo_t probeInfo;
Scene* scene;
ret = scenemanager_getinstancep();
probeBlockStart();
- if(unlikely(initialized == 0))
+ if (unlikely(initialized == 0))
{
- if(likely(ret != NULL))
+ if (likely(ret != NULL))
{
ret->AddSceneManagerEventListener(SceneManagerEventListener::GetInstance());
initialized = 1;