static void _my_cache_descriptor_shutdown(void) { eet_data_descriptor_free(_my_cache_descriptor); eet_data_descriptor_free(_my_account_descriptor); eet_data_descriptor_free(_my_message_descriptor); eet_data_descriptor_free(_my_post_descriptor); } /* _my_cache_descriptor_shutdown */
static void _emotion_webcams_edds_free(void) { eet_data_descriptor_free(_webcams_edd); _webcams_edd = NULL; eet_data_descriptor_free(_webcam_edd); _webcam_edd = NULL; }
void histogram_cache_descriptor_shutdown(void) { eet_data_descriptor_free(_histogram_descriptor); eet_data_descriptor_free(_histogram_cache_descriptor); if(cache_file) { eet_close(cache_file); } eet_shutdown(); eina_shutdown(); }
void _evas_3d_eet_descriptor_shutdown(void) { eet_data_descriptor_free(_geometry_descriptor); eet_data_descriptor_free(_vertex_descriptor); eet_data_descriptor_free(_vec2_descriptor); eet_data_descriptor_free(_vec3_descriptor); eet_data_descriptor_free(_color_descriptor); eet_data_descriptor_free(_material_descriptor); eet_data_descriptor_free(_frame_descriptor); eet_data_descriptor_free(_mesh_descriptor); eet_data_descriptor_free(_header_descriptor); eet_data_descriptor_free(_file_descriptor); }
static inline void _config_shutdown(void) { if (!_config_descriptor) return; eet_data_descriptor_free(_config_descriptor); _config_descriptor = NULL; }
/* * @brief load the list of interfaces from a file * @param file the configuration file * @return Returns the list of interfaces */ Boot_Process_List *waiting_iface_load(const char* file) { Eet_Data_Descriptor*edd; Eet_File *f; Boot_Process_List *data; edd = waiting_iface_edd_new(); f = eet_open(file, EET_FILE_MODE_READ); EXALT_ASSERT_ADV(f!=NULL, data = malloc(sizeof(Boot_Process_List)); data->timeout = 30; data->l=NULL, "f!=NULL failed"); data = eet_data_read(f, edd, "boot process interface list"); eet_close(f); eet_data_descriptor_free(edd); EXALT_ASSERT_ADV(data!=NULL, data = malloc(sizeof(Boot_Process_List)); data->timeout = 30; data->l=NULL, "data!=NULL failed"); return data; }
static inline void _session_window_shutdown(void) { if (!_session_window_descriptor) return; eet_data_descriptor_free(_session_window_descriptor); _session_window_descriptor = NULL; }
static inline void _fav_shutdown(void) { if (!_fav_descriptor) return; eet_data_descriptor_free(_fav_descriptor); _fav_descriptor = NULL; }
static inline void _hist_item_shutdown(void) { if (!_hist_item_descriptor) return; eet_data_descriptor_free(_hist_item_descriptor); _hist_item_descriptor = NULL; }
void eli_highscore_shutdown(void) { /* free the data */ ecore_hash_free_value_cb_set(hiscore_hash, ECORE_FREE_CB(_eli_highscore_list_free)); ecore_hash_destroy(hiscore_hash); eet_data_descriptor_free(edd_hiscore); eet_data_descriptor_free(edd_entry); free(eet_file_name); /* and the set the pointer to null */ hiscore_hash = NULL; edd_hiscore = NULL; edd_entry = NULL; eet_file_name = NULL; eet_shutdown(); }
EAPI void e_config_descriptor_free(E_Config_DD *edd) { #if (EET_VERSION_MAJOR > 1) || (EET_VERSION_MINOR >= 8) eina_hash_del_by_key(config_hash, eet_data_descriptor_name_get((Eet_Data_Descriptor*)edd)); #else eina_hash_del_by_data(config_hash, edd); #endif eet_data_descriptor_free((Eet_Data_Descriptor*)edd); }
int main(int argc, char **argv) { Eet_Data_Descriptor *sedd; Eet_Data_Descriptor *dedd; Simple s = { .count = 5, .value = 98, .flags = 0x5 }; Flottant f = { .x = 3.14159264, .y = 42.0 }; Simple *rs; Flottant *rf; eina_init(); eet_init(); sedd = simple_edd(); dedd = flottant_edd(); config_save(sedd, "config", "simple", &s); config_save(dedd, "config", "flottant", &f); rs = config_load(sedd, "config", "simple"); rf = config_load(dedd, "config", "flottant"); if (!rs) fprintf(stderr, "Simple structure is empty !\n"); else fprintf(stderr, "Simpe = { .count = %i, .value = %i, .flags = %x }\n", rs->count, rs->value, rs->flags); if (!rf) fprintf(stderr, "Flottant is empty\n"); else fprintf(stderr, "Flottant = { .x = %f, .y = %f }\n", rf->x, rf->y); eet_data_descriptor_free(sedd); eet_data_descriptor_free(dedd); eet_shutdown(); return 0; }
/** * @brief Save the connection associated to an essid in the configuration file * @param file the configuration file * @param c the connection * @return Returns 1 if success, else 0 */ int _exalt_eet_wireless_conn_save(const char*file, Exalt_Connection* c) { Eet_Data_Descriptor* edd; Eet_File* f; int res; edd = exalt_conn_edd_new(); f = eet_open(file, EET_FILE_MODE_READ_WRITE); if(!f) f = eet_open(file, EET_FILE_MODE_WRITE); res=eet_data_write(f, edd,exalt_conn_get_essid(c), c, 0); EXALT_ASSERT(res!=0); eet_close(f); eet_data_descriptor_free(edd); return res; }
/** * @brief Load the connection associated to an essid from the configuration file * @param file the configuration file * @param essid the essid * @return Returns the connection if success, else NULL */ Exalt_Connection* _exalt_eet_wireless_conn_load(const char*file, const char* essid) { Exalt_Connection *data = NULL; Eet_Data_Descriptor *edd; Eet_File *f; edd = exalt_conn_edd_new(); f = eet_open(file, EET_FILE_MODE_READ); EXALT_ASSERT_RETURN(f!=NULL); data = eet_data_read(f, edd, essid); eet_close(f); eet_data_descriptor_free(edd); return data; }
/** * @brief Save a Exalt_Eth_Save structure in the configuration file * @param file the configuration file * @param s the Exalt_Eth_Save strucuture * @param udi the hal udi of the interface * @return Returns 1 if success, else 0 */ int _exalt_eet_eth_save(const char* file, Exalt_Eth_Save* s, const char* udi) { Eet_Data_Descriptor *edd; Eet_File* f; int res; edd = _exalt_eth_save_edd_new(); f = eet_open(file, EET_FILE_MODE_READ_WRITE); if(!f) f = eet_open(file, EET_FILE_MODE_WRITE); res=eet_data_write(f, edd,udi, s, 0); EXALT_ASSERT(res!=0); eet_close(f); eet_data_descriptor_free(edd); return res; }
/** * @brief Load the information about an interface from the configuration file * The information are saved in a Exalt_Eth_Save structure * @param file the configuration file * @param udi the hal udi of the interface * @return Returns the information */ Exalt_Eth_Save* _exalt_eet_eth_load(const char* file, const char* udi) { Exalt_Eth_Save *data = NULL; Eet_Data_Descriptor *edd; Eet_File *f; edd = _exalt_eth_save_edd_new(); f = eet_open(file, EET_FILE_MODE_READ); EXALT_ASSERT_RETURN(f!=NULL); data = eet_data_read(f, edd, udi); eet_close(f); eet_data_descriptor_free(edd); return data; }
/* * @brief save the list of interfaces * @param l the list * @param file the configuration file */ void waiting_iface_save(const Boot_Process_List* l, const char* file) { Eet_Data_Descriptor* edd; Eet_File* f; EXALT_ASSERT_RETURN_VOID(l!=NULL); EXALT_ASSERT_RETURN_VOID(file!=NULL); edd = waiting_iface_edd_new(); f = eet_open(file, EET_FILE_MODE_READ_WRITE); if(!f) { f = eet_open(file, EET_FILE_MODE_WRITE); } eet_data_write(f, edd,"boot process interface list", l, 0); eet_close(f); eet_data_descriptor_free(edd); }
void Config::releaseEetDescriptors() { eet_data_descriptor_free(edd_cache); eet_data_descriptor_free(edd_state); }
void ece_example_descriptor_shutdown(void) { eet_data_descriptor_free(_ece_example_descriptor); }
static void _my_conf_descriptor_shutdown(void) { eet_data_descriptor_free(_my_conf_descriptor); } /* _my_conf_descriptor_shutdown */