16 #ifndef OSFI_C_INTERFACE
17 #define OSFI_C_INTERFACE 1
22 # define MAX_LENGTH_FILE_NAME 255
23 # define MAX_LENGTH_STRING 255
24 # define MAX_PARAMETER_FIELD_SIZE 255
25 # define MAX_PARAMETER_NAME_SIZE 255
26 # define MAX_PARAMETER_DESC_SIZE 255
27 # define MAX_LOG_SIZE 1000
31 #if __STDC_VERSION__ >= 201112L
32 #define OSFI_NO_RETURN _Noreturn
34 #define OSFI_NO_RETURN
71 void osfiLoggerError(
const char *format,...);
77 void osfiLoggerWarning(
const char *format,...);
83 void osfiLoggerInfo(
const char *format,...);
92 void osfiLoggerDebug(
const char *format,...);
99 void osfiLoggerProgress(
int n,
int m);
106 OSFI_NO_RETURN
void osfiLoggerFinishExecution(
int errorCode);
113 void osfiLoggerQuality(
const char *name,
const char *value);
120 void osfiLoggerQualityDouble(
const char *name,
double value);
128 int osfiCLP(
int argc,
char *argv[]);
137 void osfiCLPGetConfFile(
char * fileName,
int *length);
144 void osfiCLPGetConfFiles(
char *confFiles[],
int *noFiles);
151 void osfiCLPGetInputFiles(
char *inputFiles[],
int *noFiles);
158 void osfiCLPGetOutputFiles(
char *outputFiles[],
int *noFiles);
172 int osfiConFMParamReader(
const char *fileName,
const char *schemaName);
181 bool osfiConFMReadConfigFile(
const char *fileName);
184 enum osfi_confm_val_res {
186 OSFI_CONFM_VAL_PASSED = 1,
188 OSFI_CONFM_VAL_INVALID,
190 OSFI_CONFM_VAL_ERRORS,
197 enum osfi_confm_val_res osfiConFMValidateAgainst(
const char* schemaFile);
203 void osfiConFMPrintParameters();
211 int8_t month, dom, hour, minute, sec;
228 void osfiConFMGetIntegerValue(
int *value,
const char *paramName);
235 void osfiConFMGetDoubleValue(
double *value,
const char *paramName);
249 bool osfiConFMGetBoolValue(
const char *paramName);
257 void osfiConFMGetFileValue(
char *param,
int *length,
const char *paramName);
265 void osfiConFMGetStringValue(
char *param,
int *length,
const char *paramName);
272 void osfiConFMGetParameter(
osfiParameter *param,
const char *paramName);
278 void osfiConFMPrintParameter(
const char *paramName);
286 void osfiConFMGetVectorDoubleValues(
double *doubleList,
int *size,
287 const char *paramName);
295 void osfiConFMGetVectorIntegerValues(
int *intList,
int *size,
const char *paramName);
303 void osfiConFMGetVectorTimeValues(
osfi_timevalue_t *list,
int *size,
const char *paramName);
311 void osfiConFMGetVectorStringValues(
char *stringList[],
int *size,
const char *paramName);
319 void osfiConFMGetVectorFileValues(
char *fileList[],
int *size,
const char *paramName);
327 void osfiConFMGetVectorBooleanValues(
bool *boolList,
int *size,
const char *paramName);
335 void osfiConFMGetLeafVectorDoubleValues(
double *doubleList,
int *size,
336 const char *paramName,
int node[],
int depth);
344 void osfiConFMGetLeafVectorIntegerValues(
int *intList,
int *size,
const char *paramName,
int node[],
int depth);
352 void osfiConFMGetLeafVectorTimeValues(
osfi_timevalue_t *list,
int *size,
const char *paramName,
int node[],
int depth);
360 void osfiConFMGetLeafVectorStringValues(
char *stringList[],
int *size,
const char *paramName,
int node[],
int depth);
368 void osfiConFMGetLeafVectorFileValues(
char *fileList[],
int *size,
const char *paramName,
int node[],
int depth);
376 void osfiConFMGetLeafVectorBooleanValues(
bool *boolList,
int *size,
const char *paramName,
int node[],
int depth);
385 void osfiConFMGetMatrixStringValues(
char *stringMatrix[],
int *rows,
int *columns,
const char *paramName);
394 void osfiConFMGetMatrixFileValues(
char *fileMatrix[],
int *rows,
int *columns,
const char *paramName);
403 void osfiConFMGetMatrixBooleanValues(
bool *booleanMatrix,
int *rows,
int *columns,
const char *paramName);
412 void osfiConFMfileExist(
bool *booleanMatrix,
int *rows,
int *columns,
const char *paramName);
421 void osfiConFMGetMatrixDoubleValues(
double *doubleMatrix,
int *rows,
422 int *columns,
const char *paramName);
431 void osfiConFMGetMatrixIntegerValues(
int *intMatrix,
int *rows,
int *columns,
432 const char *paramName);
441 void osfiConFMGetMatrixTimeValues(
osfi_timevalue_t *intMatrix,
int *rows,
int *columns,
442 const char *paramName);
450 void osfiConFMGetDimension(
const char *paramName,
int index,
int *size);
452 void osfiConFMGetNodeDimension(
const char *paramName,
int node[],
int depth,
int *size);
454 bool osfiConFMIsLeaf(
const char *paramName,
int node[],
int depth);
460 int osfiConFMGetRows(
const char *paramName);
467 int osfiConFMGetColumns(
const char *paramName);
474 bool osfiConFMExistParameter(
const char *paramName);
477 ParamType osfiConFMGetElementType(
const char* paramName);
480 bool osfiConFMIsArray(
const char* paramName);
486 int osfiCommonClose();
488 #endif // !defined(OSFI_C_INTERFACE)