1064bab1dSCameron Smith #ifndef PHSOLVER_PHIO_BASE_H 2064bab1dSCameron Smith #define PHSOLVER_PHIO_BASE_H 3064bab1dSCameron Smith struct phio_file { 4064bab1dSCameron Smith struct phio_ops const* ops; 5064bab1dSCameron Smith int* file; 6ab645d52SCameron Smith char mode; 7064bab1dSCameron Smith }; 8064bab1dSCameron Smith typedef struct phio_file* phio_fp; 9064bab1dSCameron Smith struct phio_ops { 10ab645d52SCameron Smith void (*openfile)( 11ab645d52SCameron Smith const char keyphrase[], 12ab645d52SCameron Smith phio_fp fileDescriptor); 13ab645d52SCameron Smith void (*closefile)( 14ab645d52SCameron Smith phio_fp fileDescriptor); 15064bab1dSCameron Smith void (*readheader)( 16064bab1dSCameron Smith int* fileDescriptor, 17064bab1dSCameron Smith const char keyphrase[], 18064bab1dSCameron Smith void* valueArray, 19064bab1dSCameron Smith int* nItems, 20064bab1dSCameron Smith const char datatype[], 21064bab1dSCameron Smith const char iotype[] ); 22064bab1dSCameron Smith void (*writeheader)( 23064bab1dSCameron Smith const int* fileDescriptor, 24064bab1dSCameron Smith const char keyphrase[], 25064bab1dSCameron Smith const void* valueArray, 26064bab1dSCameron Smith const int* nItems, 27064bab1dSCameron Smith const int* ndataItems, 28064bab1dSCameron Smith const char datatype[], 29064bab1dSCameron Smith const char iotype[] ); 30064bab1dSCameron Smith void (*readdatablock)( 31064bab1dSCameron Smith int* fileDescriptor, 32064bab1dSCameron Smith const char keyphrase[], 33064bab1dSCameron Smith void* valueArray, 34064bab1dSCameron Smith int* nItems, 35064bab1dSCameron Smith const char datatype[], 36064bab1dSCameron Smith const char iotype[] ); 37064bab1dSCameron Smith void (*writedatablock)( 38064bab1dSCameron Smith const int* fileDescriptor, 39064bab1dSCameron Smith const char keyphrase[], 40064bab1dSCameron Smith const void* valueArray, 41064bab1dSCameron Smith const int* nItems, 42064bab1dSCameron Smith const char datatype[], 43064bab1dSCameron Smith const char iotype[]); 44*a93de25bSCameron Smith void (*constructname)( 45*a93de25bSCameron Smith const char inName[], 46*a93de25bSCameron Smith char* outName); 47064bab1dSCameron Smith }; 48064bab1dSCameron Smith 49064bab1dSCameron Smith #endif 50