/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
{
xbt_assert(s4u::Engine::get_instance()->netpoint_by_name_or_null(get_name()), "Element '%s' not found", get_cname());
if (parent_) {
{
xbt_assert(s4u::Engine::get_instance()->netpoint_by_name_or_null(get_name()), "Element '%s' not found", get_cname());
if (parent_) {
type_ = parent_->type_->by_name_or_create<ContainerType>(type_name);
parent_->children_.try_emplace(get_name(), this);
on_creation(*this);
type_ = parent_->type_->by_name_or_create<ContainerType>(type_name);
parent_->children_.try_emplace(get_name(), this);
on_creation(*this);