Software: Apache/2.0.54 (Fedora). PHP/5.0.4 uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 uid=48(apache) gid=48(apache) groups=48(apache) Safe-mode: OFF (not secure) /usr/share/gtk-doc/html/glib/ drwxr-xr-x |
Viewing file: Select action/file-type:
Synopsis#include <glib.h> GCache; GCache* g_cache_new (GCacheNewFunc value_new_func, GCacheDestroyFunc value_destroy_func, GCacheDupFunc key_dup_func, GCacheDestroyFunc key_destroy_func, GHashFunc hash_key_func, GHashFunc hash_value_func, GEqualFunc key_equal_func); gpointer g_cache_insert (GCache *cache, gpointer key); void g_cache_remove (GCache *cache, gconstpointer value); void g_cache_destroy (GCache *cache); void g_cache_key_foreach (GCache *cache, GHFunc func, gpointer user_data); void g_cache_value_foreach (GCache *cache, GHFunc func, gpointer user_data); void (*GCacheDestroyFunc) (gpointer value); gpointer (*GCacheDupFunc) (gpointer value); gpointer (*GCacheNewFunc) (gpointer key); DescriptionA GCache allows sharing of complex data structures, in order to save system resources. GTK+ uses caches for GtkStyles and GdkGCs. These consume a lot of resources, so a GCache is used to see if a GtkStyle or GdkGC with the required properties already exists. If it does, then the existing object is used instead of creating a new one. GCache uses keys and values. A GCache key describes the properties of a particular resource. A GCache value is the actual resource. DetailsGCachetypedef struct _GCache GCache; The GCache struct is an opaque data structure containing information about a GCache. It should only be accessed via the following functions. g_cache_new ()GCache* g_cache_new (GCacheNewFunc value_new_func, GCacheDestroyFunc value_destroy_func, GCacheDupFunc key_dup_func, GCacheDestroyFunc key_destroy_func, GHashFunc hash_key_func, GHashFunc hash_value_func, GEqualFunc key_equal_func); Creates a new GCache.
g_cache_insert ()gpointer g_cache_insert (GCache *cache, gpointer key);
Gets the value corresponding to the given key, creating it if necessary.
It first checks if the value already exists in the GCache, by using
the g_cache_remove ()void g_cache_remove (GCache *cache, gconstpointer value);
Decreases the reference count of the given value.
If it drops to 0 then the value and its corresponding key are destroyed,
using the
g_cache_destroy ()void g_cache_destroy (GCache *cache); Frees the memory allocated for the GCache. Note that it does not destroy the keys and values which were contained in the GCache.
g_cache_key_foreach ()void g_cache_key_foreach (GCache *cache, GHFunc func, gpointer user_data); Calls the given function for each of the keys in the GCache. g_cache_value_foreach ()void g_cache_value_foreach (GCache *cache, GHFunc func, gpointer user_data); Calls the given function for each of the values in the GCache. GCacheDestroyFunc ()void (*GCacheDestroyFunc) (gpointer value);
Specifies the type of the
GCacheDupFunc ()gpointer (*GCacheDupFunc) (gpointer value);
Specifies the type of the
|
:: Command execute :: | |
--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0034 ]-- |