34 COM_init( &argc, &argv);
36 std::cout <<
"After COM_init" << std::endl;
38 std::vector<double> tNext;
44 std::cout <<
"argc = " << argc << std::endl;
47 for(
int i=1; i < argc; i++){
51 for(
int j=0; j < ss.str().size(); j++){
52 if(!isdigit(ss.str()[j]) && ss.str()[j] !=
'e'
53 && ss.str()[j] !=
'E' && ss.str()[j] !=
'-'
54 && ss.str()[j] !=
'.')
64 std::cout <<
"line " << __LINE__ << std::endl;
66 for(
int i=0; i < tNext.size(); i++)
67 std::cout << tNext[i] << std::endl;
69 for(
int i=1; i < tNext.size(); i++){
70 std::cout << tNext[i] <<
" " << tNext[i-1] << std::endl;
71 if(tNext[i] <= tNext[i-1])
75 COM_LOAD_MODULE_STATIC_DYNAMIC( SolverModule,
"Window1");
78 int init_handle = COM_get_function_handle(
"Window1.Initialize");
79 bool init_func = (init_handle > 0);
80 std::cout <<
"init = " << init_handle << std::endl;
82 COM_call_function(init_handle);
86 int run_handle = COM_get_function_handle(
"Window1.Run");
87 bool run_func = (run_handle > 0);
88 std::cout <<
"run = " << run_handle << std::endl;
90 for(
int i=0; i < tNext.size(); i++){
91 std::cout <<
"Calling run function from driver" << std::endl;
92 COM_call_function(run_handle,&tNext[i]);
97 int final_handle = COM_get_function_handle(
"Window1.Finalize");
98 bool final_func = (final_handle > 0);
99 std::cout <<
"final = " << final_handle << std::endl;
101 COM_call_function(final_handle);
104 COM_UNLOAD_MODULE_STATIC_DYNAMIC( SolverModule,
"Window1");
107 std::cout <<
"After COM_finalize" << std::endl;