*
* A name associated with the ID.
*
- * uint32 expire
+ * SilcUInt32 expire
*
* Time when this cache entry expires. This is normal time() value
* plus the validity. Cache entry has expired if current time is
typedef struct {
void *id;
char *name;
- uint32 expire;
+ SilcUInt32 expire;
void *context;
} *SilcIDCacheEntry;
/***/
*
* SYNOPSIS
*
- * SilcIDCache silc_idcache_alloc(uint32 count, SilcIdType id_type,
+ * SilcIDCache silc_idcache_alloc(SilcUInt32 count, SilcIdType id_type,
* SilcIDCacheDestructor destructor);
*
* DESCRIPTION
* cache.
*
***/
-SilcIDCache silc_idcache_alloc(uint32 count, SilcIdType id_type,
+SilcIDCache silc_idcache_alloc(SilcUInt32 count, SilcIdType id_type,
SilcIDCacheDestructor destructor);
/****f* silccore/SilcIDCacheAPI/silc_idcache_free
* Add new entry to the cache. Returns TRUE if the entry was added and
* FALSE if it could not be added. The `name' is the name associated with
* the ID, the `id' the actual ID and the `context' a used specific context.
- * If the `expire' is TRUE the entry expires in default time and if FALSE
- * the entry never expires from the cache.
+ * If the `expire' is non-zero the entry expires in that specified time.
+ * If zero the entry never expires from the cache.
+ *
+ * If the `ret' is non-NULL the created ID Cache entry is returned to
+ * that pointer.
*
***/
bool silc_idcache_add(SilcIDCache cache, char *name, void *id,
- void *context, int expire);
+ void *context, int expire, SilcIDCacheEntry *ret);
/****f* silccore/SilcIDCacheAPI/silc_idcache_del
*