summaryrefslogtreecommitdiff
path: root/vapi/libxml-2.0.vapi
diff options
context:
space:
mode:
authorRichard Schwarting <aquarichy@gmail.com>2013-02-08 00:57:57 -0800
committerEvan Nemerson <evan@coeus-group.com>2013-02-08 00:57:57 -0800
commit3f247723fb2084c0e3dd966c40d9b9929edcfd36 (patch)
treea0af4291ee9ff6d41ea8765dae1cf511d1baa5e6 /vapi/libxml-2.0.vapi
parent1d9e7ae8631f8ab70ae842b3379f1efc7f1e3985 (diff)
downloadvala-3f247723fb2084c0e3dd966c40d9b9929edcfd36.tar.gz
libxml-2.0: add HashTable
Partially fixes bug 677355.
Diffstat (limited to 'vapi/libxml-2.0.vapi')
-rw-r--r--vapi/libxml-2.0.vapi30
1 files changed, 30 insertions, 0 deletions
diff --git a/vapi/libxml-2.0.vapi b/vapi/libxml-2.0.vapi
index 31c3db5ac..e0f5ef680 100644
--- a/vapi/libxml-2.0.vapi
+++ b/vapi/libxml-2.0.vapi
@@ -608,6 +608,36 @@ namespace Xml {
public const string name;
}
+ [CCode (has_target = false, cname = "xmlHashScannerFull", cheader_filename = "libxml/hash.h")]
+ public delegate void HashScannerFull (void *payload, void *user_data, string name, string name2, string name3);
+
+ [CCode (has_target = false, cname = "xmlHashDeallocator", cheader_filename = "libxml/hash.h")]
+ public delegate void HashDeallocator (void *payload, string name);
+
+ [Compact]
+ [CCode (cname = "xmlHashTable", cheader_filename="libxml/hash.h")]
+ public class HashTable {
+ [CCode (cname = "xmlHashCreate")]
+ public HashTable (int size);
+
+ [CCode (cname = "xmlHashAddEntry")]
+ public int add_entry (string name, void *user_data);
+
+ [CCode (cname = "xmlHashFree")]
+ public void free (HashDeallocator? f);
+
+ [CCode (cname = "xmlHashLookup")]
+ public void *lookup (string name);
+
+ [CCode (cname = "xmlHashRemoveEntry")]
+ public int remove_entry (string name, HashDeallocator? f);
+
+ [CCode (cname = "xmlHashScanFull")]
+ public void scan_full (HashScannerFull f, void *user_data);
+
+ [CCode (cname = "xmlHashSize")]
+ public int size ();
+ }
[Compact]
[CCode (cname = "xmlNode", free_function = "xmlFreeNode", cheader_filename = "libxml/tree.h")]