Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
a158f4f29ed9b75b4b611777139b48fb8bab1f92
[simgrid.git] / src / cxx / Task.hpp
1 /*\r
2  * Task.hpp\r
3  *\r
4  * This file contains the declaration of the wrapper class of the native MSG task type.\r
5  *\r
6  * Copyright 2006,2007 Martin Quinson, Malek Cherier           \r
7  * All right reserved. \r
8  *\r
9  * This program is free software; you can redistribute \r
10  * it and/or modify it under the terms of the license \r
11  *(GNU LGPL) which comes with this package. \r
12  *\r
13  */  \r
14  \r
15 #ifndef MSG_TASK_HPP\r
16 #define MSG_TASK_HPP\r
17 \r
18 // Compilation C++ recquise\r
19 #ifndef __cplusplus\r
20         #error Task.hpp requires C++ compilation (use a .cxx suffix)\r
21 #endif\r
22 \r
23 #include <msg/datatypes.h>\r
24 \r
25 #include <Config.hpp>\r
26 \r
27 #include <Object.hpp>\r
28 \r
29 namespace SimGrid\r
30 {\r
31         namespace Msg\r
32         {\r
33                 class MsgException;\r
34                 class InvalidArgumentException;\r
35                 class NullPointerException;\r
36                 class MsgException;\r
37                 class BadAllocException;\r
38 \r
39                 class Process;\r
40                 class Host;\r
41 \r
42                 // SimGrid::Msg::Task wrapper class declaration.\r
43                 class SIMGRIDX_EXPORT Task : public Object\r
44                 {\r
45                         MSG_DECLARE_DYNAMIC(Task);\r
46 \r
47                         friend Process;\r
48                         friend Host;\r
49 \r
50                         protected:\r
51                                 // Default constructor.\r
52                                 Task();\r
53 \r
54                         class Ref\r
55                         {\r
56                         public:\r
57                                 Ref(Task* task)\r
58                                 {\r
59                                         count = 1;\r
60                                         this->task = task;\r
61                                 }\r
62 \r
63                                 virtual ~Ref(){}\r
64 \r
65                                 void operator++(void){\r
66                                         count++;\r
67                                         \r
68                                 }\r
69 \r
70                                 void operator--(void){\r
71                                         if(--count <= 0)\r
72                                                 delete p;\r
73                                 }\r
74 \r
75                         private:\r
76                                 int count;\r
77                                 Task* task;\r
78 \r
79                         };\r
80                                 \r
81                         public:\r
82                                 /*! \brief Copy constructor.\r
83                                  */\r
84                                 Task(const Task& rTask);\r
85                                 \r
86                                 /*! \brief Destructor.\r
87                                  *\r
88                                  * \exception                           If the destructor failed, it throw the exception described below:\r
89                                  *\r
90                                  *                                                      [MsgException]                          if a native exception occurs.\r
91                                  */\r
92                                 virtual ~Task()\r
93                                 throw(MsgException);\r
94                                 \r
95                                 /*! \brief Constructs an new task with the specified processing amount and amount\r
96                                  * of data needed.\r
97                                  *\r
98                                  * \param name                          Task's name\r
99                                  * \param computeDuration       A value of the processing amount (in flop) needed to process the task. \r
100                                  *                                                      If 0, then it cannot be executed with the execute() method.\r
101                                  *                                                      This value has to be >= 0.\r
102                                  * \param messageSize           A value of amount of data (in bytes) needed to transfert this task.\r
103                                  *                                                      If 0, then it cannot be transfered with the get() and put() methods.\r
104                                  *                                                      This value has to be >= 0.\r
105                                  *\r
106                                  * \exception                           If this method failed, it throws one of the exceptions described below:\r
107                                  *\r
108                                  *                                                      [InvalidArgumentException]      if the parameter computeDuration or messageSize\r
109                                  *                                                                                                              is negative.\r
110                                  *                                                      [NullPointerException]          if the parameter name is NULL.\r
111                                  *\r
112                                  *                                                      [MsgException]                          if a internal exception occurs.\r
113                                  */\r
114                                 Task(const char* name, double computeDuration, double messageSize)\r
115                                 throw (InvalidArgumentException, NullPointerException);\r
116                                 \r
117                                 /*! \Constructs an new parallel task with the specified processing amount and amount for each host\r
118                              * implied.\r
119                              *\r
120                              * \param name                              The name of the parallel task.\r
121                              * \param hosts                             The list of hosts implied by the parallel task.\r
122                              * \param computeDurations  The amount of operations to be performed by each host of \a hosts.\r
123                              * \param messageSizes              A matrix describing the amount of data to exchange between hosts.\r
124                              * \hostCount                               The number of hosts implied in the parallel task.\r
125                              * \r
126                              * \exception                               If this method fails, it throws one of the exceptions described below:\r
127                              *\r
128                              *                                                  [NullPointerException]          if the parameter name is NULL or\r
129                              *                                                                                                          if the parameter computeDurations is NULL or\r
130                              *                                                                                                          if the parameter messageSizes is NULL\r
131                              *\r
132                              *                                                  [InvalidArgumentException]      if the parameter hostCount is negative or zero.                                                 \r
133                              */\r
134                                 Task(const char* name, Host* hosts, double* computeDurations, double* messageSizes, int hostCount)\r
135                                 throw(NullPointerException, InvalidArgumentException);\r
136                         \r
137                         \r
138                                 /*! \brief Task::getName() - Gets the names of the task.\r
139                                  *\r
140                                  * \return                                      The name of the task.\r
141                                  */\r
142                                 const char* getName(void) const;\r
143                         \r
144                                 /*! \brief Task::getSender() - Gets the sender of the task.\r
145                                  *\r
146                                  * \return                                      A reference to the sender of the task.\r
147                                  */\r
148                                 Process& getSender(void) const;\r
149                                 \r
150                                 /*! \brief Task::getSource() - Gets the source of the task.\r
151                                  * \r
152                                  * \return                                      A reference to the source of the task.\r
153                                  */\r
154                                 Host& getSource(void) const;\r
155                                 \r
156                                 /*! \brief Task::getComputeDuration() - Get the computing amount of the task.\r
157                                  *\r
158                                  * \return                                      The computing amount of the task.\r
159                                  */\r
160                         \r
161                                 double getComputeDuration(void) const;\r
162                                 \r
163                                 /*! \brief Task::getRemainingDuration() - Gets the remaining computation.\r
164                                  *\r
165                                  * \return                                      The remining computation of the task.\r
166                                  */\r
167                                 double getRemainingDuration(void) const;\r
168                         \r
169                                 /*! \brief Task::setPrirority() -  Sets the priority of the computation of the task.\r
170                          * The priority doesn't affect the transfert rate. For example a\r
171                          * priority of 2 will make the task receive two times more cpu than\r
172                          * the other ones.\r
173                          *\r
174                          * \param priority                      The new priority of the task.\r
175                          *\r
176                          * execption                            If this method fails, it throws the exception described below:\r
177                          *\r
178                          *                                                      [InvalidArgumentException]      if the parameter priority is negative.\r
179                          */\r
180                                 void setPriority(double priority)\r
181                                 throw(InvalidArgumentException);\r
182                                 \r
183                                 /*! \brief Task::get() - Gets a task from the specified channel of the host of the current process.\r
184                                  *\r
185                                  * \param channel                       The channel number to get the task.\r
186                                  *\r
187                                  * \return                                      If successful the method returns the task. Otherwise the method throws one\r
188                                  *                                                      of the exceptions described below:\r
189                                  *\r
190                                  * \exception                           [InvalidArgumentException]      if the channel parameter is negative.\r
191                                  *                                      \r
192                                  *                                                      [MsgException]                          if an internal excpetion occurs.\r
193                                  */\r
194                                 /*static Task& get(int channel) \r
195                                 throw(InvalidArgumentException, MsgException);*/\r
196 \r
197                                 static Task* get(int channel) \r
198                                 throw(InvalidArgumentException, MsgException);\r
199 \r
200                                 /*! \brief      Task::get() - Gets a task from the given channel number of the given host.      \r
201                                  *\r
202                                  * \param channel                       The channel number.\r
203                                  * \param rHost                         A reference of the host owning the channel.\r
204                                  *\r
205                                  * \return                                      If successful, the method returns the task. Otherwise the method\r
206                                  *                                                      throw one of the exceptions described below:\r
207                                  *\r
208                                  * \exception                           [InvalidArgumentException]      if the channel number is negative.\r
209                                  *\r
210                                  *                                                      [MsgException]                          if an internal exception occurs.\r
211                                  */\r
212                                 static Task& get(int channel, const Host& rHost) \r
213                                 throw(InvalidArgumentException, MsgException);\r
214                                 \r
215                                 /*! \brief Task::get() - Gets a task from the specified channel of the specified host\r
216                                  *  (waiting at most given time).\r
217                                  *\r
218                                  * \param channel                       The channel number.\r
219                                  * \param timeout                       The timeout value.\r
220                                  * \param rHost                         A reference to the host owning the channel.\r
221                                  *\r
222                                  * \return                                      If successful, the method returns the task. Otherwise the method returns\r
223                                  *                                                      one of the exceptions described below:\r
224                                  *\r
225                                  * \exception                           [InvalidArgumentException]      if the channel number is negative or\r
226                                  *                                                                                                              if the timeout value is negative and \r
227                                  *                                                                                                              different than -1.0.\r
228                                  *                                                      [MsgException]                          if an internal exception occurs.\r
229                                  */\r
230                                 static Task& get(int channel, double timeout, const Host& rHost) \r
231                                 throw(InvalidArgumentException, MsgException);  \r
232                                 \r
233                                 /*! \brief Task::probe() - Probes whether there is a waiting task on the given channel of local host.\r
234                                  *\r
235                                  * \param channel                       The channel number.\r
236                                  *\r
237                                  * \return                                      If there is a waiting task on the channel the method returns 1. Otherwise\r
238                                  *                                                      the method returns 0.\r
239                                  *\r
240                                  * \exception                           If this method fails, it throws the exception described below:\r
241                                  *\r
242                                  *                                                      [InvalidArgumentException]      if the parameter channel is negative.\r
243                                  */\r
244                                 static int probe(int channel)\r
245                                 throw(InvalidArgumentException);\r
246                                 \r
247                                 /*! \brief Task::probe() - Counts tasks waiting on the given channel of local host and sent by given host.\r
248                                  *\r
249                                  * \param channel                       The channel id.\r
250                                  * \param rHost                         A reference to the host that has sent the task.\r
251                                  *\r
252                                  * \return                                      The number of tasks.\r
253                                  *\r
254                                  * \exception                           [InvalidArgumentException]      if the parameter channel is negative.\r
255                                  */\r
256                                 static int probe(int channel, const Host& rHost)\r
257                                 throw(InvalidArgumentException);\r
258                                 \r
259                                 /*! \brief Task::execute() - This method executes a task on the location on which the\r
260                                  * process is running.\r
261                                  *\r
262                                  * \exception                           If this method fails, it returns the exception described below:\r
263                                  *\r
264                                  *                                                      [MsgException]                          if an internal exception occurs.\r
265                                  */\r
266                                 void execute(void) \r
267                                 throw(MsgException);\r
268                                 \r
269                                 /*! \brief Task::cancel() - This method cancels a task.\r
270                                  *\r
271                                  * \exception                           If this method fails, it returns the exception described below:\r
272                                  *\r
273                                  *                                                      [MsgException]                          if an internal exception occurs.\r
274                                  */\r
275                                 void cancel(void) \r
276                                 throw(MsgException);\r
277                         \r
278                                 /*! \brief Task::send() - Send the task on the mailbox identified by the default alias.\r
279                                  *\r
280                                  * \exception                           If this method failed, it returns one of the exceptions described\r
281                                  *                                                      below:\r
282                                  *\r
283                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default alias.\r
284                                  *\r
285                                  *                                                      [MsgException]                          if an internal exception occurs.\r
286                                  */\r
287                                 void send(void) \r
288                                 throw(BadAllocException, MsgException);\r
289                                 \r
290                                 /*! \brief Task::send() - Send the task on the mailbox identified by the given alias.\r
291                                  *\r
292                                  * \param alias                         The alias of the mailbox where to send the task.\r
293                                  *\r
294                                  * \exception                           If this method failed, it returns one of the exceptions described\r
295                                  *                                                      below:\r
296                                  *\r
297                                  *                                                      [NullPointerException]          if there parameter alias is NULL.\r
298                                  *\r
299                                  *                                                      [MsgException]                          if an internal exception occurs.\r
300                                  */ \r
301                                 void send(const char* alias) \r
302                                 throw(NullPointerException, MsgException);\r
303                                 \r
304                                 /*! \brief Task::send() - Send the task on the mailbox identified by the default alias\r
305                                  * (waiting at most given time).\r
306                                  *\r
307                                  * \param timeout                       The timeout value.\r
308                                  *\r
309                                  * \exception                           If this method failed, it returns one of the exceptions described\r
310                                  *                                                      below:\r
311                                  *\r
312                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default alias.\r
313                                  *\r
314                                  *                                                      [InvalidArgumentException]      if the timeout value is negative or different -1.0.\r
315                                  *\r
316                                  *                                                      [MsgException]                          if an internal exception occurs.\r
317                                  */\r
318                                 void send(double timeout) \r
319                                 throw(BadAllocException, InvalidArgumentException, MsgException);\r
320                                 \r
321                                 /*! \brief Task::send() - Send the task on the mailbox identified by a given alias\r
322                                  * (waiting at most given time).\r
323                                  *\r
324                                  * \param alias                         The alias of the mailbox where to send the task.\r
325                                  * \param timeout                       The timeout value.\r
326                                  *\r
327                                  * \exception                           If this method failed, it returns one of the exceptions described\r
328                                  *                                                      below:\r
329                                  *\r
330                                  *                                                      [NullPointerException]          if alias parameter is NULL.\r
331                                  *\r
332                                  *                                                      [InvalidArgumentException]      if the timeout value is negative or different -1.0.\r
333                                  *\r
334                                  *                                                      [MsgException]                          if an internal exception occurs.\r
335                                  */\r
336                                 void send(const char* alias, double timeout) \r
337                                 throw(NullPointerException, InvalidArgumentException, MsgException);\r
338                                 \r
339                                 /*! \brief Task::sendBounded() - Sends the task on the mailbox identified by the default alias.\r
340                                  * (capping the emision rate to maxrate).\r
341                                  *\r
342                                  * \param maxRate                       The maximum rate value.\r
343                                  *\r
344                                  * \exception                           If this method failed, it throws one of the exceptions described below:\r
345                                  *\r
346                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default alias.\r
347                                  *\r
348                                  *                                                      [InvalidArgumentException]      if the parameter maxRate is negative and different\r
349                                  *                                                                                                              than -1.0.\r
350                                  *\r
351                                  *                                                      [MsgException]                          if an internal exception occurs.\r
352                                  */\r
353                                 void sendBounded(double maxRate) \r
354                                 throw(BadAllocException, InvalidArgumentException, MsgException);\r
355                                 \r
356                                 /*! \brief Task::sendBounded() - Sends the task on the mailbox identified by the given alias.\r
357                                  * (capping the emision rate to maxrate).\r
358                                  *\r
359                                  *\ param alias                         The alias of the mailbox where to send the task.\r
360                                  * \param maxRate                       The maximum rate value.\r
361                                  *\r
362                                  * \exception                           If this method failed, it throws one of the exceptions described below:\r
363                                  *\r
364                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
365                                  *\r
366                                  *                                                      [InvalidArgumentException]      if the parameter maxRate is negative and different\r
367                                  *                                                                                                              than -1.0.\r
368                                  *\r
369                                  *                                                      [MsgException]                          if an internal exception occurs.\r
370                                  */\r
371                                 void sendBounded(const char* alias, double maxRate) \r
372                                 throw(NullPointerException, InvalidArgumentException, MsgException);\r
373                                 \r
374                                 \r
375                                 /*! \brief Task::receive() - Receives a task from the mailbox identified by the default alias (located\r
376                                  * on the local host).\r
377                                  *\r
378                                  * \return                                      A reference to the task.\r
379                                  *\r
380                                  * \exception                           If this method failed, it throws one of the exception described below:\r
381                                  *\r
382                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default alias.\r
383                                  *\r
384                                  *                                                      [MsgException]                          if an internal exception occurs.\r
385                                  */\r
386                                 /*static Task& receive(void) \r
387                                 throw(BadAllocException, MsgException);*/\r
388 \r
389                                 static Task* receive(void) \r
390                                 throw(BadAllocException, MsgException);\r
391                                 \r
392                                 /*! \brief Task::receive() - Receives a task from the mailbox identified by a given alias (located\r
393                                  * on the local host).\r
394                                  *\r
395                                  * \alias                                       The alias of the mailbox.\r
396                                  *\r
397                                  * \return                                      A reference to the task.\r
398                                  *\r
399                                  * \exception                           If this method failed, it throws one of the exception described below:\r
400                                  *\r
401                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
402                                  *\r
403                                  *                                                      [MsgException]                          if an internal exception occurs.\r
404                                  */\r
405                                 /*static Task& receive(const char* alias) \r
406                                 throw(NullPointerException, MsgException);*/\r
407                                 static Task* receive(const char* alias) \r
408                                 throw(NullPointerException, MsgException);\r
409                                 \r
410                                 /*! \brief Task::receive() - Receives a task from the mailbox identified by a given alias (located\r
411                                  * on the local host and waiting at most given time).\r
412                                  *\r
413                                  * \alias                                       The alias of the mailbox.\r
414                                  * \timeout                                     The timeout value.\r
415                                  *\r
416                                  * \return                                      A reference to the task.\r
417                                  *\r
418                                  * \exception                           If this method failed, it throws one of the exception described below:\r
419                                  *\r
420                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
421                                  *\r
422                                  *                                                      [InvalidArgumentException]      if the timeout value is negatif and different than\r
423                                  *                                                                                                              -1.0.\r
424                                  *\r
425                                  *                                                      [MsgException]                          if an internal exception occurs.\r
426                                  */\r
427                                 static Task& receive(const char* alias, double timeout) \r
428                                 throw(NullPointerException, InvalidArgumentException, MsgException);\r
429                                 \r
430                                 /*! \brief Task::receive() - Receives a task from the mailbox identified by a given alias located\r
431                                  * on the given host.\r
432                                  *\r
433                                  * \alias                                       The alias of the mailbox.\r
434                                  * \rHost                                       The location of the mailbox.\r
435                                  *\r
436                                  * \return                                      A reference to the task.\r
437                                  *\r
438                                  * \exception                           If this method failed, it throws one of the exception described below:\r
439                                  *\r
440                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
441                                  *\r
442                                  *                                                      [MsgException]                          if an internal exception occurs.\r
443                                  */\r
444                                 static Task& receive(const char* alias, const Host& rHost) \r
445                                 throw(NullPointerException, MsgException);\r
446                                 \r
447                                 /*! \brief Task::receive() - Receives a task from the mailbox identified by a given alias located\r
448                                  * on the given host (and waiting at most given time).\r
449                                  *\r
450                                  * \alias                                       The alias of the mailbox.\r
451                                  * \timeout                                     The timeout value.\r
452                                  * \rHost                                       The location of the mailbox.\r
453                                  *\r
454                                  * \return                                      A reference to the task.\r
455                                  *\r
456                                  * \exception                           If this method failed, it throws one of the exception described below:\r
457                                  *\r
458                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
459                                  *\r
460                                  *                                                      [InvalidArgumentException]      if the timeout value is negatif and different than\r
461                                  *                                                                                                              -1.0.\r
462                                  *\r
463                                  *                                                      [MsgException]                          if an internal exception occurs.\r
464                                  */\r
465                                 static Task& receive(const char* alias, double timeout, const Host& rHost) \r
466                                 throw(NullPointerException, InvalidArgumentException, MsgException);\r
467                                 \r
468                                 /*! \brief Task::listen() - Listen whether there is a waiting task on the mailbox \r
469                                  * identified by the default alias of local host.\r
470                                  *\r
471                                  * \return                                      If there is a waiting task on the mailbox the method returns true.\r
472                                  *                                                      Otherwise the method returns false.\r
473                                  *\r
474                                  * \exception                           If this method fails, it throws one of the exceptions described below:\r
475                                  *\r
476                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default alias.\r
477                                  */\r
478                                 static int listen(void) \r
479                                 throw(BadAllocException);\r
480                                 \r
481                                 /*! \brief Task::listen() - Listen whether there is a waiting task on the mailbox \r
482                                  * identified by the given alias of local host.\r
483                                  *\r
484                                  * \param alias                         The alias of the mailbox.\r
485                                  *\r
486                                  * \return                                      If there is a waiting task on the mailbox the method returns 1.\r
487                                  *                                                      Otherwise the method returns 0.\r
488                                  *\r
489                                  * \exception                           If this method fails, it throws one of the exceptions described below:\r
490                                  *\r
491                                  *                                                      [NullPointerException]          if the parameter alias is NULL.\r
492                                  */\r
493                                 static int listen(const char* alias) \r
494                                 throw(NullPointerException);\r
495                                 \r
496                                 /*! \brief Task::listenFrom() - Tests whether there is a pending communication on the mailbox \r
497                                  * identified by the default alias, and who sent it.\r
498                                  *\r
499                                  * \return                                      If there is a pending communication on the mailbox, the method returns\r
500                                  *                                                      the PID of it sender. Otherwise the method returns -1.\r
501                                  *\r
502                                  * \exception                           If this method fails, it throws the exception described below:\r
503                                  *\r
504                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default\r
505                                  *                                                                                                              alias.\r
506                                  */\r
507                                 static int listenFrom(void) \r
508                                 throw(BadAllocException);\r
509                                 \r
510                                 /*! \brief Task::listenFrom() - Tests whether there is a pending communication on the mailbox \r
511                                  * identified by the specified alias, and who sent it.\r
512                                  *\r
513                                  * \alias                                       The alias of the mailbox.\r
514                                  *\r
515                                  * \return                                      If there is a pending communication on the mailbox, the method returns\r
516                                  *                                                      the PID of it sender. Otherwise the method returns -1.\r
517                                  *\r
518                                  * \exception                           If this method fails, it throws the exception described below:\r
519                                  *\r
520                                  *                                                      [NullPointerException]          if the alias parameter is NULL.\r
521                                  */\r
522                                 static int listenFrom(const char* alias) \r
523                                 throw(NullPointerException);\r
524                                 \r
525                                 /*! \brief Task::listenFromHost() - Tests whether there is a pending communication on the mailbox \r
526                                  * identified by the default alias and located on the host of the current process, and who sent it.\r
527                                  *\r
528                                  * \param rHost                         The location of the mailbox.\r
529                                  *\r
530                                  * \return                                      If there is a pending communication on the mailbox, the method returns\r
531                                  *                                                      the PID of it sender. Otherwise the method returns -1.\r
532                                  *\r
533                                  * \exception                           If this method fails, it throws the exception described below:\r
534                                  *\r
535                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default\r
536                                  *                                                                                                              alias.\r
537                                  */\r
538                                 static int listenFromHost(const Host& rHost) \r
539                                 throw(BadAllocException);\r
540                                 \r
541                                 /*! \brief Task::listenFromHost() - Tests whether there is a pending communication on the mailbox \r
542                                  * identified by the default alias and located on the host of the current process, and who sent it.\r
543                                  *\r
544                                  * \param rHost                         The location of the mailbox.\r
545                                  *\r
546                                  * \return                                      If there is a pending communication on the mailbox, the method returns\r
547                                  *                                                      the PID of it sender. Otherwise the method returns -1.\r
548                                  *\r
549                                  * \exception                           If this method fails, it throws the exception described below:\r
550                                  *\r
551                                  *                                                      [BadAllocException]                     if there is not enough memory to build the default\r
552                                  *                                                                                                              alias.\r
553                                  */\r
554                                 static int listenFromHost(const char* alias, const Host& rHost) \r
555                                 throw(NullPointerException, MsgException);\r
556 \r
557                                 virtual const Task& operator= (const Task& rTask);\r
558                         \r
559                         protected:\r
560                                 \r
561                                 // Attributes.\r
562                                 \r
563                                 m_task_t nativeTask;    // the native MSG task.\r
564 \r
565                                 Ref* ref;\r
566                 };\r
567         \r
568         } // namespace Msg \r
569 } // namespace SimGrid\r
570 \r
571 typedef Task* TaskPtr;\r
572 \r
573 #endif // §MSG_TASK_HPP