[C API] Add interface to the new PureFluid property pairs
This commit is contained in:
parent
71e2101cdf
commit
c1f287d648
2 changed files with 77 additions and 0 deletions
|
|
@ -601,6 +601,76 @@ extern "C" {
|
|||
}
|
||||
}
|
||||
|
||||
int th_set_ST(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_ST(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_TV(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_TV(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_PV(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_PV(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_UP(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_UP(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_VH(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_VH(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_TH(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_TH(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_set_SH(int n, double* vals)
|
||||
{
|
||||
try {
|
||||
ThermoCabinet::item(n).setState_SH(vals[0],vals[1]);
|
||||
return 0;
|
||||
} catch (...) {
|
||||
return handleAllExceptions(-1, ERR);
|
||||
}
|
||||
}
|
||||
|
||||
int th_equil(int n, char* XY, int solver,
|
||||
double rtol, int maxsteps, int maxiter, int loglevel)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -78,6 +78,13 @@ extern "C" {
|
|||
CANTERA_CAPI int th_set_UV(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_SV(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_SP(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_ST(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_TV(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_PV(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_UP(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_VH(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_TH(int n, double* vals);
|
||||
CANTERA_CAPI int th_set_SH(int n, double* vals);
|
||||
CANTERA_CAPI int th_equil(int n, char* XY, int solver,
|
||||
double rtol, int maxsteps, int maxiter, int loglevel);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue