* The basic class type - should be removed, just for compat.
* @deprecated
*/
-typedef struct _Eo_Opaque Eo_Class;
+typedef Eo Eo_Class;
/**
* @typedef Eo_Callback_Priority
* You must use this macro if you want thread safety in class creation.
*/
#define EO_DEFINE_CLASS(class_get_func_name, class_desc, parent_class, ...) \
-EAPI const Eo * \
+EAPI const Eo_Class * \
class_get_func_name(void) \
{ \
- const Eo *_tmp_parent_class; \
+ const Eo_Class *_tmp_parent_class; \
static volatile char lk_init = 0; \
static Eina_Lock _my_lock; \
- static const Eo * volatile _my_class = NULL; \
+ static const Eo_Class * volatile _my_class = NULL; \
if (EINA_LIKELY(!!_my_class)) return _my_class; \
\
eina_lock_take(&_eo_class_creation_lock); \
} ops; /**< The ops description, should be filled using #EO_CLASS_DESCRIPTION_OPS */
const Eo_Event_Description **events; /**< The event descriptions for this class. */
size_t data_size; /**< The size of data (private + protected + public) this class needs per object. */
- void (*class_constructor)(Eo *klass); /**< The constructor of the class. */
- void (*class_destructor)(Eo *klass); /**< The destructor of the class. */
+ void (*class_constructor)(Eo_Class *klass); /**< The constructor of the class. */
+ void (*class_destructor)(Eo_Class *klass); /**< The destructor of the class. */
};
/**
*
* @see #EO_DEFINE_CLASS
*/
-EAPI const Eo *eo_class_new(const Eo_Class_Description *desc, const Eo *parent, ...);
+EAPI const Eo_Class *eo_class_new(const Eo_Class_Description *desc, const Eo_Class *parent, ...);
/**
* @brief Check if an object "is a" klass.
*
* Notice: This function does not support composite objects.
*/
-EAPI Eina_Bool eo_isa(const Eo *obj, const Eo *klass);
+EAPI Eina_Bool eo_isa(const Eo *obj, const Eo_Class *klass);
/**
* @brief Sets the OP functions for a class.
*
* Should be called from within the class constructor.
*/
-EAPI void eo_class_funcs_set(Eo *klass, const Eo_Op_Func_Description *func_descs);
+EAPI void eo_class_funcs_set(Eo_Class *klass, const Eo_Op_Func_Description *func_descs);
/**
* @brief Gets the name of the passed class.
*
* @see eo_class_get()
*/
-EAPI const char *eo_class_name_get(const Eo *obj);
+EAPI const char *eo_class_name_get(const Eo_Class *klass);
/**
* @}
* @see #eo_do
* @see #eo_do_super
*/
-EAPI Eina_Bool eo_do_super_internal(const char *file, int line, const Eo *obj, const Eo *cur_klass, Eo_Op op, ...);
+EAPI Eina_Bool eo_do_super_internal(const char *file, int line, const Eo *obj, const Eo_Class *cur_klass, Eo_Op op, ...);
/**
* @brief Gets the class of the object.
*
* @see eo_class_name_get()
*/
-EAPI const Eo *eo_class_get(const Eo *obj);
+EAPI const Eo_Class *eo_class_get(const Eo *obj);
/**
* @def eo_error_set
*/
#define eo_add(klass, parent, ...) \
({ \
- const Eo *_tmp_klass = klass; \
+ const Eo_Class *_tmp_klass = klass; \
eo_add_internal(__FILE__, __LINE__, _tmp_klass, parent, eo_constructor(), ## __VA_ARGS__, EO_NOOP); \
})
*/
#define eo_add_custom(klass, parent, ...) \
({ \
- const Eo *_tmp_klass = klass; \
+ const Eo_Class *_tmp_klass = klass; \
eo_add_internal(__FILE__, __LINE__, _tmp_klass, parent, ## __VA_ARGS__, EO_NOOP); \
})
*
* @see #eo_add
*/
-EAPI Eo *eo_add_internal(const char *file, int line, const Eo *klass, Eo *parent, ...);
+EAPI Eo *eo_add_internal(const char *file, int line, const Eo_Class *klass, Eo *parent, ...);
/**
* @brief Get a pointer to the data of an object for a specific class.
* @return a pointer to the data.
* @deprecated use eo_data_scope_get or eo_data_ref instead.
*/
-EAPI void *eo_data_get(const Eo *obj, const Eo *klass) EINA_DEPRECATED;
+EAPI void *eo_data_get(const Eo *obj, const Eo_Class *klass) EINA_DEPRECATED;
/**
* @brief Get a pointer to the data of an object for a specific class.
* @see eo_data_ref()
* @see eo_data_unref()
*/
-EAPI void *eo_data_scope_get(const Eo *obj, const Eo *klass);
+EAPI void *eo_data_scope_get(const Eo *obj, const Eo_Class *klass);
/**
* @def eo_data_xref(obj, klass, ref_obj)
*
* @see eo_data_xunref_internal()
*/
-EAPI void *eo_data_xref_internal(const char *file, int line, const Eo *obj, const Eo *klass, const Eo *ref_obj);
+EAPI void *eo_data_xref_internal(const char *file, int line, const Eo *obj, const Eo_Class *klass, const Eo *ref_obj);
/**
* @def eo_data_xunref(obj, data, ref_obj)
* @brief Use #EO_BASE_CLASS
* @internal
* */
-EAPI const Eo *eo_base_class_get(void);
+EAPI const Eo_Class *eo_base_class_get(void);
/**
* @typedef eo_base_data_free_func
}
static inline _Eo_Class *
-_eo_class_pointer_get(const Eo *klass_id)
+_eo_class_pointer_get(const Eo_Class *klass_id)
{
#ifdef HAVE_EO_ID
return ID_CLASS_GET((Eo_Id)klass_id);
}
EAPI Eina_Bool
-eo_do_super_internal(const char *file, int line, const Eo *obj_id, const Eo *cur_klass_id, Eo_Op op, ...)
+eo_do_super_internal(const char *file, int line, const Eo *obj_id, const Eo_Class *cur_klass_id, Eo_Op op, ...)
{
const _Eo_Class *nklass;
Eina_Bool op_ret = EINA_TRUE;
return (ret & op_ret);
}
-EAPI const Eo *
+EAPI const Eo_Class *
eo_class_get(const Eo *obj_id)
{
if (_eo_is_a_class(obj_id))
}
EAPI const char *
-eo_class_name_get(const Eo *obj_id)
+eo_class_name_get(const Eo_Class *obj_id)
{
const _Eo_Class *klass;
}
EAPI void
-eo_class_funcs_set(Eo *klass_id, const Eo_Op_Func_Description *func_descs)
+eo_class_funcs_set(Eo_Class *klass_id, const Eo_Op_Func_Description *func_descs)
{
EO_CLASS_POINTER_RETURN(klass_id, klass);
/* Do nonthing. */
}
-EAPI const Eo *
-eo_class_new(const Eo_Class_Description *desc, const Eo *parent_id, ...)
+EAPI const Eo_Class *
+eo_class_new(const Eo_Class_Description *desc, const Eo_Class *parent_id, ...)
{
_Eo_Class *klass;
va_list p_list;
extn_id = va_arg(p_list, Eo_Id *);
while (extn_id)
{
- extn = _eo_class_pointer_get((Eo *)extn_id);
+ extn = _eo_class_pointer_get((Eo_Class *)extn_id);
switch (extn->desc->type)
{
case EO_CLASS_TYPE_REGULAR:
}
EAPI Eina_Bool
-eo_isa(const Eo *obj_id, const Eo *klass_id)
+eo_isa(const Eo *obj_id, const Eo_Class *klass_id)
{
EO_OBJ_POINTER_RETURN_VAL(obj_id, obj, EINA_FALSE);
EO_CLASS_POINTER_RETURN_VAL(klass_id, klass, EINA_FALSE);
}
EAPI Eo *
-eo_add_internal(const char *file, int line, const Eo *klass_id, Eo *parent_id, ...)
+eo_add_internal(const char *file, int line, const Eo_Class *klass_id, Eo *parent_id, ...)
{
Eina_Bool do_err;
_Eo_Object *obj;
}
EAPI void *
-eo_data_get(const Eo *obj_id, const Eo *klass_id)
+eo_data_get(const Eo *obj_id, const Eo_Class *klass_id)
{
return eo_data_scope_get(obj_id, klass_id);
}
EAPI void *
-eo_data_scope_get(const Eo *obj_id, const Eo *klass_id)
+eo_data_scope_get(const Eo *obj_id, const Eo_Class *klass_id)
{
void *ret;
EO_OBJ_POINTER_RETURN_VAL(obj_id, obj, NULL);
}
EAPI void *
-eo_data_xref_internal(const char *file, int line, const Eo *obj_id, const Eo *klass_id, const Eo *ref_obj_id)
+eo_data_xref_internal(const char *file, int line, const Eo *obj_id, const Eo_Class *klass_id, const Eo *ref_obj_id)
{
void *ret;
EO_OBJ_POINTER_RETURN_VAL(obj_id, obj, NULL);