Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Instr: for consistency, rename 'father' to 'parent' here too.
[simgrid.git] / src / instr / instr_paje_types.hpp
index a5e31d4..b30eb76 100644 (file)
@@ -22,7 +22,7 @@ class Type {
   long long int id_ = new_paje_id();
   std::string name_;
   std::string color_;
-  Type* father_;
+  Type* parent_;
   std::map<std::string, std::unique_ptr<Type>, std::less<>> children_;
   Container* issuer_ = nullptr;
 
@@ -33,14 +33,14 @@ public:
   static xbt::signal<void(Type const&, PajeEventType event_type)> on_creation;
 
   Type(PajeEventType event_type, const std::string& name, const std::string& alias, const std::string& color,
-       Type* father);
+       Type* parent);
   virtual ~Type() = default;
 
   long long int get_id() const { return id_; }
   const std::string& get_name() const { return name_; }
   const char* get_cname() const { return name_.c_str(); }
   const std::string& get_color() const { return color_; }
-  Type* get_father() const { return father_; }
+  Type* get_parent() const { return parent_; }
   const std::map<std::string, std::unique_ptr<Type>, std::less<>>& get_children() const { return children_; }
   bool is_colored() const { return not color_.empty(); }
 
@@ -64,15 +64,15 @@ public:
 class ContainerType : public Type {
 public:
   explicit ContainerType(const std::string& name) : Type(PajeEventType::DefineContainerType, name, name, "", nullptr){};
-  ContainerType(const std::string& name, Type* father)
-      : Type(PajeEventType::DefineContainerType, name, name, "", father){};
+  ContainerType(const std::string& name, Type* parent)
+      : Type(PajeEventType::DefineContainerType, name, name, "", parent){};
 };
 
 class VariableType : public Type {
   std::vector<VariableEvent*> events_;
 public:
-  VariableType(const std::string& name, const std::string& color, Type* father)
-      : Type(PajeEventType::DefineVariableType, name, name, color, father)
+  VariableType(const std::string& name, const std::string& color, Type* parent)
+      : Type(PajeEventType::DefineVariableType, name, name, color, parent)
   {
   }
   void instr_event(double now, double delta, const char* resource, double value);
@@ -84,10 +84,10 @@ public:
 class ValueType : public Type {
 public:
   std::map<std::string, EntityValue, std::less<>> values_;
-  ValueType(PajeEventType event_type, const std::string& name, const std::string& alias, Type* father)
-      : Type(event_type, name, alias, "", father){};
-  ValueType(PajeEventType event_type, const std::string& name, Type* father)
-      : Type(event_type, name, name, "", father){};
+  ValueType(PajeEventType event_type, const std::string& name, const std::string& alias, Type* parent)
+      : Type(event_type, name, alias, "", parent){};
+  ValueType(PajeEventType event_type, const std::string& name, Type* parent)
+      : Type(event_type, name, name, "", parent){};
   void add_entity_value(const std::string& name, const std::string& color);
   void add_entity_value(const std::string& name);
   EntityValue* get_entity_value(const std::string& name);
@@ -96,8 +96,8 @@ public:
 class LinkType : public ValueType {
 public:
   static xbt::signal<void(LinkType const&, Type const&, Type const&)> on_creation;
-  LinkType(const std::string& name, const Type* source, const Type* dest, const std::string& alias, Type* father)
-      : ValueType(PajeEventType::DefineLinkType, name, alias, father)
+  LinkType(const std::string& name, const Type* source, const Type* dest, const std::string& alias, Type* parent)
+      : ValueType(PajeEventType::DefineLinkType, name, alias, parent)
   {
     on_creation(*this, *source, *dest);
   }
@@ -108,13 +108,13 @@ public:
 
 class EventType : public ValueType {
 public:
-  EventType(const std::string& name, Type* father) : ValueType(PajeEventType::DefineEventType, name, father) {}
+  EventType(const std::string& name, Type* parent) : ValueType(PajeEventType::DefineEventType, name, parent) {}
 };
 
 class StateType : public ValueType {
   std::vector<StateEvent*> events_;
 public:
-  StateType(const std::string& name, Type* father) : ValueType(PajeEventType::DefineStateType, name, father) {}
+  StateType(const std::string& name, Type* parent) : ValueType(PajeEventType::DefineStateType, name, parent) {}
   void set_event(const std::string& value_name);
   void push_event(const std::string& value_name);
   void push_event(const std::string& value_name, TIData* extra);