ns-3 Direct Code Execution
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
dce-manager-helper.h
Go to the documentation of this file.
1 #ifndef DCE_MANAGER_HELPER_H
2 #define DCE_MANAGER_HELPER_H
3 
4 #include "ns3/object-factory.h"
5 #include "ns3/attribute.h"
6 #include "ns3/object-base.h"
7 #include "ns3/node-container.h"
8 #include "ns3/nstime.h"
9 #include <string>
10 
11 namespace ns3 {
12 
18 {
19 public:
20  ProcStatus (int n, int e, int p, int64_t ns, int64_t ne, long rs, long re, double nd, long rd, std::string cmd);
21 
25  int GetNode (void) const;
29  int GetExitCode (void) const;
33  int GetPid (void) const;
37  int64_t GetSimulatedStartTime (void) const;
41  int64_t GetSimulatedEndTime (void) const;
45  long GetRealStartTime (void) const;
49  long GetRealEndTime (void) const;
53  double GetSimulatedDuration (void) const;
57  long GetRealDuration (void) const;
61  std::string GetCmdLine (void) const;
62 
63 private:
64  int m_node;
66  int m_pid;
67  int64_t m_ns3StartTime;
68  int64_t m_ns3EndTime;
71  double m_ns3Duration;
73  std::string m_cmdLine;
74 };
75 
80 class DceManagerHelper : public Object
81 {
82 public:
83  static TypeId GetTypeId (void);
84  virtual TypeId GetInstanceTypeId (void) const;
85 
90 
100  void SetScheduler (std::string type,
101  std::string n0 = "", const AttributeValue &v0 = EmptyAttributeValue (),
102  std::string n1 = "", const AttributeValue &v1 = EmptyAttributeValue ());
103 
114  void SetDelayModel (std::string type,
115  std::string n0 = "", const AttributeValue &v0 = EmptyAttributeValue (),
116  std::string n1 = "", const AttributeValue &v1 = EmptyAttributeValue ());
117 
124  void SetTaskManagerAttribute (std::string n0, const AttributeValue &v0);
125 
131  void SetLoader (std::string type);
132 
141  void SetNetworkStack (std::string type,
142  std::string n0 = "", const AttributeValue &v0 = EmptyAttributeValue ());
143 
150  void SetAttribute (std::string n1, const AttributeValue &v1);
151 
158  void Install (NodeContainer nodes);
159 
166  void SetVirtualPath (std::string p);
167 
172  std::string GetVirtualPath () const;
173 
179  static std::vector<ProcStatus> GetProcStatus (void);
180 
181 private:
182  ObjectFactory m_loaderFactory;
183  ObjectFactory m_schedulerFactory;
184  ObjectFactory m_taskManagerFactory;
185  ObjectFactory m_managerFactory;
186  ObjectFactory m_networkStackFactory;
187  ObjectFactory m_delayFactory;
188  std::string m_virtualPath;
189  static unsigned long nanoCpt;
190 };
191 
192 } // namespace ns3
193 
194 #endif /* DCE_MANAGER_HELPER_H */