+ std::list<actor::Simcall*> simcalls_; /* List of simcalls waiting for this activity */
+ s4u::Activity* piface_ = nullptr;
+ resource::Action* model_action_ = nullptr; /* The resource consumption in the used model */
+
+protected:
+ void inline set_name(std::string_view name)
+ {
+ // This is to keep name_ private while allowing ActivityImpl_T<??> to set it and then return a Ptr to qualified
+ // child type
+ name_ = name;
+ }
+ void set_start_time(double start_time) { start_time_ = start_time; }
+ void clear_hosts() { hosts_.clear(); }
+ void add_host(s4u::Host* host) { hosts_.push_back(host); }
+ void set_hosts(const std::vector<s4u::Host*>& hosts) { hosts_ = hosts; }
+
+public:
+ const std::string& get_name() const { return name_; }
+ const char* get_cname() const { return name_.c_str(); }
+
+ void set_actor(actor::ActorImpl* actor) { actor_ = actor; }
+ actor::ActorImpl* get_actor() const { return actor_; }
+
+ void set_iface(s4u::Activity* iface) { piface_ = iface; }
+ s4u::Activity* get_iface() { return piface_; }
+
+ void set_state(State state) { state_ = state; }
+ const State& get_state() const { return state_; }
+ const char* get_state_str() const;
+
+ double get_start_time() const { return start_time_; }
+ void set_finish_time(double finish_time) { finish_time_ = finish_time; }
+ double get_finish_time() const { return finish_time_; }
+
+ virtual bool test(actor::ActorImpl* issuer);
+ static ssize_t test_any(actor::ActorImpl* issuer, const std::vector<ActivityImpl*>& activities);
+
+ virtual void wait_for(actor::ActorImpl* issuer, double timeout);
+ static void wait_any_for(actor::ActorImpl* issuer, const std::vector<ActivityImpl*>& activities, double timeout);
+ virtual ActivityImpl& set_timeout(double) { THROW_UNIMPLEMENTED; }