31 static shared_ptr<Solution>
create() {
32 return shared_ptr<Solution>(
new Solution );
36 std::string
name()
const;
84 AnyMap parameters(
bool withInput=
false)
const;
91 const std::string
source()
const;
125shared_ptr<Solution>
newSolution(
const std::string& infile,
const std::string& name,
126 const std::string& transport,
const std::vector<std::string>& adjacent);
141shared_ptr<Solution>
newSolution(
const std::string& infile,
142 const std::string& name=
"",
143 const std::string& transport=
"",
144 const std::vector<shared_ptr<Solution>>& adjacent={});
165 const AnyMap& phaseNode,
const AnyMap& rootNode=AnyMap(),
166 const std::string& transport=
"",
167 const std::vector<shared_ptr<Solution>>& adjacent={},
168 const std::map<std::string, shared_ptr<Solution>>& related={});
A map of string keys to values whose type can vary at runtime.
A container class holding managers for all pieces defining a phase.
static shared_ptr< Solution > create()
Create an empty Solution object.
std::string name() const
Return the name of this Solution object.
shared_ptr< Kinetics > kinetics()
Accessor for the Kinetics pointer.
void addAdjacent(shared_ptr< Solution > adjacent)
Add a phase adjacent to this phase.
void setSource(const std::string &source)
Overwrite source (only required if object is not created using newSolution)
shared_ptr< Kinetics > m_kinetics
Kinetics manager.
virtual void setThermo(shared_ptr< ThermoPhase > thermo)
Set the ThermoPhase object.
shared_ptr< ThermoPhase > m_thermo
ThermoPhase manager.
std::map< std::string, shared_ptr< Solution > > m_adjacentByName
Adjacent phases, for access by name.
void setName(const std::string &name)
Set the name of this Solution object.
AnyMap m_header
Additional input fields; usually from a YAML input file.
shared_ptr< Solution > adjacent(const std::string &name)
Get the Solution object for an adjacent phase by name.
size_t nAdjacent() const
Get the number of adjacent phases.
std::vector< shared_ptr< Solution > > m_adjacent
Adjacent phases, for access by index.
virtual void setTransport(shared_ptr< Transport > transport)
Set the Transport object.
const std::string source() const
Retrieve source used for object creation; usually an input file name.
shared_ptr< ThermoPhase > thermo()
Accessor for the ThermoPhase pointer.
shared_ptr< Transport > transport()
Accessor for the Transport pointer.
const AnyMap & header() const
Access input data associated with header definition.
shared_ptr< Solution > adjacent(size_t i)
Get the Solution object for an adjacent phase by index.
shared_ptr< Transport > m_transport
Transport manager.
virtual void setKinetics(shared_ptr< Kinetics > kinetics)
Set the Kinetics object.
Definitions for the classes that are thrown when Cantera experiences an error condition (also contain...
Namespace for the Cantera kernel.
shared_ptr< Solution > newSolution(const std::string &infile, const std::string &name, const std::string &transport, const std::vector< std::string > &adjacent)
Create and initialize a new Solution from an input file.