afc_dynamic_class_master_add

Name

afc_dynamic_class_master_add  -- Adds a new Dynamic Class in memory

Synopsis

int afc_dynamic_class_master_add ( DynamicClassMaster * dcm, char * class_name, void * handler, DynamicClass * ( *new_inst ) (), int ( *del_inst ) (DynamicClass *), chat * (*info) (int) );

Description

This function adds a DynamicClass in memory. This is very usefull if you want to add "static" DynamicClasses that are not loaded directly from a file, but already present in memory. This is a "low level" function, because it is not so easy to use. Since this function is used directly by afc_dynamic_class_master_load() you have to specify a dllib handler as third param. This can be set to NULL if you are adding a class already in memory.

Inputs

dcm

Pointer to a valid afc_dynamic_class_master instance.

class_name

Name to assign to the class loaded

handler

The dllib handler. This can be set to NULL if you are adding a "static" class.

new_inst

Pointer to the function to be used when creating a new DynamicClass instance.

del_inst

Pointer to the function to be used when deleting a DynamicClass instance.

info

Pointer to the function to be used to get info about a DynamicClass. This can be set to NULL.

Result

should be AFC_ERR_NO_ERROR

Note

See Also