Remote Administration Daemon Developer Guide

Exit Print View

Updated: July 2014
 
 

Container Interactions

Function
Description
conerr_t rad_cont_insert(rad_container_t *container, adr_name_t *name, rad_instance_t *instance);
Create an instance, rad_instance_t, using the supplied name and object and then insert into container. If the operation succeeds, CE_OK is returned.
conerr_t rad_cont_insert_singleton(rad_container_t *container, adr_name_t *name, rad_object_t *object);
void rad_cont_remove(rad_container_t *container, adr_name_t *name);
Remove the instance from the container.
conerr_t rad_cont_register_dynamic(rad_container_t *container, adr_name_t *name, rad_modinfo_t *modinfo, rad_dyn_list_t listf, rad_dyn_lookup_t lookupf, void *arg);
Register a dynamic container instance manager. The container defines the container in which the instances will be managed. The name defines the name filter for which this instance manager is responsible. A typical name would define the type of the instance which are managed. For example, zname = adr_name_vcreate (MOD_DOMAIN, 1, "type", "Zone") would be responsible for managing all instances with a type of "Zone". listf is a user-supplied function which is invoked when objects with the matching pattern are listed. lookupf is a user-supplied function which is invoked when objects with the matching name are looked up. arg is stored and provided in the callback to the user functions.
conerr_t (*rad_dyn_list_t)(adr_pattern_t *pattern, adr_data_t **data, void *arg);
conerr_t (*rad_dyn_lookup_t)(adr_name_t **name, rad_instance_t **inst, void *arg);