allows changing model units on-the-fly

replaces PR #140
and with special thanks to @eladsal
This commit is contained in:
Sam Hatchett
2018-01-11 15:22:26 -05:00
parent 3892b65759
commit d2503bc035
4 changed files with 95 additions and 5 deletions

View File

@@ -513,6 +513,13 @@ extern "C" {
*/
int DLLEXPORT ENgetflowunits(int *code);
/**
@brief Sets the flow units
@param code Code of flow units to use
@return Error code
*/
int DLLEXPORT ENsetflowunits(int code);
/**
@brief Retrieves the index of the time pattern with specified ID
@param id String ID of the time pattern
@@ -1149,6 +1156,7 @@ extern "C" {
int DLLEXPORT EN_getoption(EN_Project *p, EN_Option opt, EN_API_FLOAT_TYPE *value);
int DLLEXPORT EN_gettimeparam(EN_Project *p, int code, long *value);
int DLLEXPORT EN_getflowunits(EN_Project *p, int *code);
int DLLEXPORT EN_setflowunits(EN_Project *p, int code);
int DLLEXPORT EN_getpatternindex(EN_Project *p, char *id, int *index);
int DLLEXPORT EN_getpatternid(EN_Project *p, int index, char *id);
int DLLEXPORT EN_getpatternlen(EN_Project *p, int index, int *len);