#ifndef client_options_h #define client_options_h #include /* client_options.h should be the only file read in by optimizers */ /* It should not #include other files. */ /* -- other files may want to include it because of this */ /* -- changes should be made with caution. */ #ifndef TRUE #define TRUE (1) #endif #ifndef FALSE #define FALSE (0) #endif /* a standard buffer length for reading input lines and stuff */ #define BUFLEN 1000 /* RET_OK and RET_BAD are the return values from call_server. */ /* They are also the standard return values from the client. */ #ifndef RET_OK #define RET_OK (0) #endif #ifndef RET_BAD #define RET_BAD (1) #endif typedef struct STRUCT_name_value_list { char *name; char *value; struct STRUCT_name_value_list *next; } name_value_list; /* name and type are not usually used by the optimizer */ typedef struct { char *name; char *type; unsigned int n_fields; name_value_list *field_data; } client_variable; typedef struct { unsigned int n_param; name_value_list *param; /* parameters */ unsigned int n_inp; client_variable *inp; /* input variables */ unsigned int n_out; client_variable *out; /* output variables */ FILE *error_file; } client_options; typedef struct { int index; char *marker; double *inp; double *out; int status; int exit_status; } server_io; extern char *find_value(char *name, name_value_list *list); extern int get_n_process(void); typedef int (server_submit)(server_io *, void *); typedef int (server_reply)(server_io **, void *); typedef int (client_function)(client_options *, server_submit *, server_reply *, void *, double *, double *); #endif