Actual source code: snesregi.c

  1: /*$Id: snesregi.c,v 1.38 2001/03/23 23:24:07 balay Exp $*/

 3:  #include src/snes/snesimpl.h

  5: EXTERN_C_BEGIN
  6: EXTERN int SNESCreate_LS(SNES);
  7: EXTERN int SNESCreate_TR(SNES);
  8: EXTERN int SNESCreate_Test(SNES);
  9: EXTERN_C_END
 10: 
 11: /*
 12:       This is used by SNESSetType() to make sure that at least one 
 13:     SNESRegisterAll() is called. In general, if there is more than one
 14:     DLL then SNESRegisterAll() may be called several times.
 15: */
 16: extern PetscTruth SNESRegisterAllCalled;

 18: /*@C
 19:    SNESRegisterAll - Registers all of the nonlinear solver methods in the SNES package.

 21:    Not Collective

 23:    Level: advanced

 25: .keywords: SNES, register, all

 27: .seealso:  SNESRegisterDestroy()
 28: @*/
 29: int SNESRegisterAll(char *path)
 30: {

 34:   SNESRegisterAllCalled = PETSC_TRUE;

 36:   SNESRegisterDynamic("ls",   path,"SNESCreate_LS",SNESCreate_LS);
 37:   SNESRegisterDynamic("tr",   path,"SNESCreate_TR",SNESCreate_TR);
 38:   SNESRegisterDynamic("test", path,"SNESCreate_Test", SNESCreate_Test);

 40:   return(0);
 41: }