# Phases and Solutions (jl-type-solution)= ::::{describe} Solution(infile, name=""; transport="default") Construct a `Solution` from a Cantera input (YAML) file. `name` selects the phase within the file (the first phase is used when empty); `transport` selects a transport model, `"default"` being the one named in the input file. ```julia gas = Solution("gri30.yaml") gas = Solution("gri30.yaml", "gri30") ``` :::: (jl-function-close-bang)= ::::{describe} close!(gas::Solution) Release the Cantera-side objects backing `gas`. Safe to call multiple times; the finalizer calls this automatically, so explicit use is only needed for deterministic cleanup. ```julia close!(f::Func1) ``` Release the Cantera-side object backing `f`. Idempotent; called automatically by the finalizer. ```julia close!(mp::MultiPhase) ``` Release the Cantera-side object backing `mp`. Idempotent. ```julia close!(d::ReactionPathDiagram) ``` Release the Cantera-side object backing `d`. Safe to call multiple times; the finalizer calls this automatically. :::: (jl-function-thermo)= ::::{describe} thermo(gas::Solution) -> ThermoPhase Return the [`ThermoPhase`](#jl-type-thermophase) view of `gas`. :::: (jl-function-kinetics)= ::::{describe} kinetics(gas::Solution) -> Kinetics Return the [`Kinetics`](#jl-type-kinetics) view of `gas`. :::: (jl-function-transport)= ::::{describe} transport(gas::Solution) -> Transport Return the [`Transport`](#jl-type-transport) view of `gas`. :::: (jl-function-name)= ::::{describe} name(gas::Solution) -> String Name of the Solution object. ```julia name(r::Reactor) ``` Reactor name. ```julia name(c::Connector) ``` Connector name. :::: (jl-function-transport-model)= ::::{describe} transport_model(gas::Solution) -> String Name of the active transport model. :::: (jl-type-canteraobject)= ::::{describe} CanteraObject Abstract supertype of all Julia wrappers around Cantera CLib objects. :::: (jl-type-thermophase)= ::::{describe} ThermoPhase Thermodynamic-phase view of a [`Solution`](#jl-type-solution). Wraps a `ThermoPhase` CLib handle and holds a reference to the owning `Solution`. :::: (jl-type-kinetics)= ::::{describe} Kinetics Kinetics view of a [`Solution`](#jl-type-solution). Wraps a `Kinetics` CLib handle and holds a reference to the owning `Solution`. :::: (jl-type-transport)= ::::{describe} Transport Transport view of a [`Solution`](#jl-type-solution). Wraps a `Transport` CLib handle and holds a reference to the owning `Solution`. ::::