get_model()->get_action_heap().remove(this);
if (modified_set_hook_.is_linked())
simgrid::xbt::intrusive_erase(*get_model()->get_modified_set(), *this);
get_model()->get_action_heap().remove(this);
if (modified_set_hook_.is_linked())
simgrid::xbt::intrusive_erase(*get_model()->get_modified_set(), *this);
return Action::State::FAILED;
if (state_set_ == model_->get_finished_action_set())
return Action::State::FINISHED;
return Action::State::FAILED;
if (state_set_ == model_->get_finished_action_set())
return Action::State::FINISHED;
sharing_priority_ = weight;
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), weight);
sharing_priority_ = weight;
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), weight);
if (modified_set_hook_.is_linked())
simgrid::xbt::intrusive_erase(*get_model()->get_modified_set(), *this);
get_model()->get_action_heap().remove(this);
}
}
if (modified_set_hook_.is_linked())
simgrid::xbt::intrusive_erase(*get_model()->get_modified_set(), *this);
get_model()->get_action_heap().remove(this);
}
}
XBT_IN("(%p)", this);
if (suspended_ != SuspendStates::sleeping) {
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), 0.0);
XBT_IN("(%p)", this);
if (suspended_ != SuspendStates::sleeping) {
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), 0.0);
get_model()->get_action_heap().remove(this);
if (state_set_ == get_model()->get_started_action_set() && sharing_priority_ > 0) {
// If we have a lazy model, we need to update the remaining value accordingly
get_model()->get_action_heap().remove(this);
if (state_set_ == get_model()->get_started_action_set() && sharing_priority_ > 0) {
// If we have a lazy model, we need to update the remaining value accordingly
if (suspended_ != SuspendStates::sleeping) {
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), get_priority());
suspended_ = SuspendStates::not_suspended;
if (suspended_ != SuspendStates::sleeping) {
get_model()->get_maxmin_system()->update_variable_weight(get_variable(), get_priority());
suspended_ = SuspendStates::not_suspended;
- /* update remains before return it */
- if (get_model()->get_update_algorithm() == Model::UpdateAlgo::Lazy) /* update remains before return it */
+ /* update remains before returning it */
+ if (get_model()->get_update_algorithm() == Model::UpdateAlgo::LAZY) /* update remains before return it */