Skip to main content

snapshot

Function snapshot 

Source
pub fn snapshot(model: &Model) -> Result<Snapshot, SolverError>
Expand description

Compute the incremental Snapshot of a linear model (LP/MILP).

The objective and every constraint must be linear, the snapshot is the basis for a persistent backend’s warm re-solve fast path and is only meaningful for linear models (a quadratic/nonlinear model always rebuilds).

§Errors

Returns SolverError::Nonlinear if the objective or any constraint is not linear, or SolverError::UnsupportedKind if the model is a second-order cone program (explicit oximo_core::SocConstraints or SOC-shaped quadratic constraints detected by Model::kind).