#[non_exhaustive]pub struct AsyncModelConfig {
pub display_name: String,
pub input_config: Option<InputConfig>,
pub output_config: Option<OutputConfig>,
pub enable_checkpoints: bool,
/* private fields */
}Expand description
Information for solving one optimization model asynchronously.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.display_name: StringUser defined model name, can be used as alias by users to keep track of models.
input_config: Option<InputConfig>Required. Information about the input model.
output_config: Option<OutputConfig>Required. The desired output location information.
enable_checkpoints: boolIf this is set, the model will be solved in the checkpoint mode. In this mode, the input model can have a deadline longer than 30 mins without the risk of interruption. The model will be solved in multiple short-running stages. Each stage generates an intermediate checkpoint and stores it in the user’s Cloud Storage buckets. The checkpoint mode should be preferred over allow_large_deadline_despite_interruption_risk since it prevents the risk of interruption.
Implementations§
Source§impl AsyncModelConfig
impl AsyncModelConfig
pub fn new() -> Self
Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sets the value of display_name.
Sourcepub fn set_input_config<T>(self, v: T) -> Selfwhere
T: Into<InputConfig>,
pub fn set_input_config<T>(self, v: T) -> Selfwhere
T: Into<InputConfig>,
Sets the value of input_config.
Sourcepub fn set_or_clear_input_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<InputConfig>,
pub fn set_or_clear_input_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<InputConfig>,
Sets or clears the value of input_config.
Sourcepub fn set_output_config<T>(self, v: T) -> Selfwhere
T: Into<OutputConfig>,
pub fn set_output_config<T>(self, v: T) -> Selfwhere
T: Into<OutputConfig>,
Sets the value of output_config.
Sourcepub fn set_or_clear_output_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<OutputConfig>,
pub fn set_or_clear_output_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<OutputConfig>,
Sets or clears the value of output_config.
Sourcepub fn set_enable_checkpoints<T: Into<bool>>(self, v: T) -> Self
pub fn set_enable_checkpoints<T: Into<bool>>(self, v: T) -> Self
Sets the value of enable_checkpoints.
Trait Implementations§
Source§impl Clone for AsyncModelConfig
impl Clone for AsyncModelConfig
Source§fn clone(&self) -> AsyncModelConfig
fn clone(&self) -> AsyncModelConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more