36 #include "CellMLLoader.hpp"
39 #include "EulerIvpOdeSolver.hpp"
42 : mCellMLFile(rCellMLFile),
43 mOutputFileHandler(rOutputFileHandler),
46 mUseCvode(boost::logic::indeterminate)
56 if (boost::logic::indeterminate(
mUseCvode))
61 std::vector<std::string>::iterator it = std::find(
mOptions.begin(),
mOptions.end(),
"--cvode");
62 if (!makeCvodeCell && it !=
mOptions.end())
66 if (makeCvodeCell && it ==
mOptions.end())
84 EXCEPTION(
"You cannot call both LoadCvodeCell and LoadCardiacCell on the same CellMLLoader.");
88 DynamicCellModelLoaderPtr p_loader =
mpConverter->Convert(copied_model);
91 boost::shared_ptr<AbstractStimulusFunction> p_stimulus;
92 boost::shared_ptr<EulerIvpOdeSolver> p_solver;
105 return p_loaded_cell;
111 boost::shared_ptr<AbstractCardiacCell> p_model(dynamic_cast<AbstractCardiacCell*>(p_loaded_cell));
119 boost::shared_ptr<AbstractCvodeCell> p_model(dynamic_cast<AbstractCvodeCell*>(p_loaded_cell));
bool HasCellMLDefaultStimulus()
OutputFileHandler mOutputFileHandler
std::vector< std::string > mOptions
boost::shared_ptr< AbstractCvodeCell > LoadCvodeCell(void)
FileFinder CopyFileTo(const FileFinder &rSourceFile) const
#define EXCEPTION(message)
FileFinder FindFile(std::string leafName) const
CellMLLoader(const FileFinder &rCellMLFile, const OutputFileHandler &rOutputFileHandler, const std::vector< std::string > &rOptions)
virtual boost::shared_ptr< RegularStimulus > UseCellMLDefaultStimulus()
boost::shared_ptr< CellMLToSharedLibraryConverter > mpConverter
AbstractCardiacCellInterface * LoadCellMLFile(bool makeCvodeCell)
std::string GetLeafNameNoExtension() const
boost::shared_ptr< AbstractCardiacCell > LoadCardiacCell(void)
boost::logic::tribool mUseCvode
std::string GetLeafName() const