Beispiel #1
0
Datei: rmf.c Projekt: hankem/ISIS
static Isis_Rmf_Load_Method_t *get_user_rmf_load_method (char *options) /*{{{*/
{
   static const char *delim = ":;";
   Isis_Rmf_Load_Method_t *load_method;
   char *s, *file, *init_name;

   if (options == NULL)
     return NULL;

   /* options string has form
    *   "libname.so:init_name[;opt1;opt2;opt3;...]"
    */

   if (NULL == (s = isis_make_string (options)))
     return NULL;

   if ((NULL == (file = strtok (s, delim)))
       || (NULL == (init_name = strtok (NULL, delim))))
     {
        ISIS_FREE(s);
        return NULL;
     }

   load_method = (Isis_Rmf_Load_Method_t *)isis_load_function (file, init_name, "rmf");

   ISIS_FREE(s);

   return load_method;
}
Beispiel #2
0
int isis_fit_load_statistic (char *file, char *sname) /*{{{*/
{
   Isis_Fit_Statistic_Init_Type *x;

   x = (Isis_Fit_Statistic_Init_Type *)isis_load_function (file, sname, "stat");
   if (x == NULL)
     return -1;

   return isis_fit_add_statistic (sname, x);
}
Beispiel #3
0
int isis_fit_load_fit_routine (char *file, char *name, char *sname) /*{{{*/
{
   Isis_Fit_Engine_Init_Type *f;

   f = (Isis_Fit_Engine_Init_Type *)isis_load_function (file, name, "feng");
   if (f == NULL)
     return -1;

   return isis_fit_add_engine (name, sname, f);
}