Struct grb::AsyncHandle[][src]

pub struct AsyncHandle(_);
Expand description

A handle to an AsyncModel which is currently solving.

Implementations

Retrieve current the attr::Status of the model.

Retrieve the current attr::ObjVal of the model.

Retrieve the current attr::ObjBound of the model.

Retrieve the current attr::IterCount of the model.

Retrieve the current attr::BarIterCount of the model.

Retrieve the current attr::NodeCount of the model.

Wait for optimisation to finish.

Errors

An Error::FromAPI may occur during optimisation, in which case it is stored in the Result.

Send a request to Gurobi to terminate optimization. Optimization may not finish immediately.

Example
use grb::AsyncModel;
let e = Env::new("")?;
let m = Model::with_env("async", e)?;
  ...
let m = AsyncModel::new(m);
// discard `AsyncModel` on failure and panic
let handle = m.optimize().map_err(|(_, e)| e).unwrap();
  ...
handle.terminate();

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.