[Python] Assign Solution to zeroD directly

This commit is contained in:
Ingmar Schoegl 2024-01-20 19:31:54 -06:00 committed by Ray Speth
parent 32f9ea6ec8
commit e9034d9061
2 changed files with 2 additions and 5 deletions

View File

@ -38,7 +38,7 @@ cdef extern from "cantera/zerodim.h" namespace "Cantera":
cdef cppclass CxxReactorBase "Cantera::ReactorBase":
CxxReactorBase()
string type()
void setThermoMgr(CxxThermoPhase&) except +translate_exception
void setSolution(shared_ptr[CxxSolution]) except +translate_exception
void restoreState() except +translate_exception
void syncState() except +translate_exception
double volume()
@ -48,7 +48,6 @@ cdef extern from "cantera/zerodim.h" namespace "Cantera":
cdef cppclass CxxReactor "Cantera::Reactor" (CxxReactorBase):
CxxReactor()
void setKineticsMgr(CxxKinetics&)
void setChemistry(cbool)
cbool chemistryEnabled()
void setEnergy(int)

View File

@ -58,7 +58,7 @@ cdef class ReactorBase:
self._thermo = solution
# Block species from being added to the phase as long as this object exists
self._thermo._references[self._weakref_proxy] = True
self.rbase.setThermoMgr(deref(solution.thermo))
self.rbase.setSolution(solution._base)
property type:
"""The type of the reactor."""
@ -268,8 +268,6 @@ cdef class Reactor(ReactorBase):
"""
ReactorBase.insert(self, solution)
self._kinetics = solution
if solution.kinetics != NULL:
self.reactor.setKineticsMgr(deref(solution.kinetics))
property kinetics:
"""