Given a routine and a string id, saves that routine in the specified registry.


#include "petsc.h" 
PetscErrorCode PETSC_DLLEXPORT PetscFListAdd(PetscFList *fl,const char name[],const char rname[],void (*fnc)(void))
Not Collective

Input Parameters

fl - pointer registry
name - string to identify routine
rname - routine name in dynamic library
fnc - function pointer (optional if using dynamic libraries)


To remove a registered routine, pass in a PETSC_NULL rname and fnc().

Users who wish to register new classes for use by a particular PETSc component (e.g., SNES) should generally call the registration routine for that particular component (e.g., SNESRegisterDynamic()) instead of calling PetscFListAddDynamic() directly.

${PETSC_ARCH}, ${PETSC_DIR}, ${PETSC_LIB_DIR}, or ${any environmental variable} occuring in pathname will be replaced with appropriate values.

See Also

PetscFListDestroy(), SNESRegisterDynamic(), KSPRegisterDynamic(),
PCRegisterDynamic(), TSRegisterDynamic(), PetscFList

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages