## EXMLHash

EXMLHash — Functions for manipulating xml as a hash table.

## Synopsis

    enum                EXmlHashType;
    GHashTable*         e_xml_to_hash                       (xmlDoc *doc,
                                                             EXmlHashType type);
    xmlDoc*             e_xml_from_hash                     (GHashTable *hash,
                                                             EXmlHashType type,
                                                             const char *root_node);
    void                e_xml_destroy_hash                  (GHashTable *hash);
    enum                EXmlHashStatus;
    void                (*EXmlHashFunc)                     (const char *key,
                                                             const char *value,
                                                             gpointer user_data);
    gboolean            (*EXmlHashRemoveFunc)               (const char *key,
                                                             const char *value,
                                                             gpointer user_data);
    typedef             EXmlHash;
    EXmlHash*           e_xmlhash_new                       (const char *filename);
    void                e_xmlhash_add                       (EXmlHash *hash,
                                                             const char *key,
                                                             const char *data);
    void                e_xmlhash_remove                    (EXmlHash *hash,
                                                             const char *key);
    EXmlHashStatus      e_xmlhash_compare                   (EXmlHash *hash,
                                                             const char *key,
                                                             const char *compare_data);
    void                e_xmlhash_foreach_key               (EXmlHash *hash,
                                                             EXmlHashFunc func,
                                                             gpointer user_data);
    void                e_xmlhash_foreach_key_remove        (EXmlHash *hash,
                                                             EXmlHashRemoveFunc func,
                                                             gpointer user_data);
    void                e_xmlhash_write                     (EXmlHash *hash);
    void                e_xmlhash_destroy                   (EXmlHash *hash);

## Description

## Details

### enum EXmlHashType

    typedef enum {
    	E_XML_HASH_TYPE_OBJECT_UID,
    	E_XML_HASH_TYPE_PROPERTY
    } EXmlHashType;

### e_xml_to_hash ()

    GHashTable*         e_xml_to_hash                       (xmlDoc *doc,
                                                             EXmlHashType type);

`doc` : |
`type` : |
Returns : |

### e_xml_from_hash ()

    xmlDoc*             e_xml_from_hash                     (GHashTable *hash,
                                                             EXmlHashType type,
                                                             const char *root_node);

`hash` : |
`type` : |
`root_node` : |
Returns : |

### e_xml_destroy_hash ()

    void                e_xml_destroy_hash                  (GHashTable *hash);

`hash` : |

### enum EXmlHashStatus

    typedef enum {
    	E_XMLHASH_STATUS_SAME,
    	E_XMLHASH_STATUS_DIFFERENT,
    	E_XMLHASH_STATUS_NOT_FOUND
    } EXmlHashStatus;

### EXmlHashFunc ()

    void                (*EXmlHashFunc)                     (const char *key,
                                                             const char *value,
                                                             gpointer user_data);

`key` : |
`value` : |
`user_data` : |

### EXmlHashRemoveFunc ()

    gboolean            (*EXmlHashRemoveFunc)               (const char *key,
                                                             const char *value,
                                                             gpointer user_data);

`key` : |
`value` : |
`user_data` : |
Returns : |

### EXmlHash

    typedef struct EXmlHash EXmlHash;

### e_xmlhash_new ()

    EXmlHash*           e_xmlhash_new                       (const char *filename);

`filename` : |
Returns : |

### e_xmlhash_add ()

    void                e_xmlhash_add                       (EXmlHash *hash,
                                                             const char *key,
                                                             const char *data);

`hash` : |
`key` : |
`data` : |

### e_xmlhash_remove ()

    void                e_xmlhash_remove                    (EXmlHash *hash,
                                                             const char *key);

`hash` : |
`key` : |

### e_xmlhash_compare ()

    EXmlHashStatus      e_xmlhash_compare                   (EXmlHash *hash,
                                                             const char *key,
                                                             const char *compare_data);

`hash` : |
`key` : |
`compare_data` : |
Returns : |

### e_xmlhash_foreach_key ()

    void                e_xmlhash_foreach_key               (EXmlHash *hash,
                                                             EXmlHashFunc func,
                                                             gpointer user_data);

`hash` : |
`func` : |
`user_data` : |

### e_xmlhash_foreach_key_remove ()

    void                e_xmlhash_foreach_key_remove        (EXmlHash *hash,
                                                             EXmlHashRemoveFunc func,
                                                             gpointer user_data);

`hash` : |
`func` : |
`user_data` : |

### e_xmlhash_write ()

    void                e_xmlhash_write                     (EXmlHash *hash);

`hash` : |

### e_xmlhash_destroy ()

    void                e_xmlhash_destroy                   (EXmlHash *hash);

`hash` : |