Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@7117 48e7efb5...
[simgrid.git] / src / bindings / ruby / rb_msg_task.h
1 #ifndef RB_MSG_TASK_H
2 #define RB_MSG_TASK_H
3
4 #include <ruby.h>
5 #include <stdio.h>
6 #include "msg/msg.h"
7 #include "msg/datatypes.h"
8 #include "xbt/sysdep.h"        
9 #include "xbt/log.h"
10 #include "xbt/asserts.h"
11
12 typedef enum {
13   PORT_22 = 0,
14   MAX_CHANNEL
15 } channel_t;
16
17 // Free Method
18 static void task_free(m_task_t tk);
19
20 // New Method  >>> Data NULL
21 static VALUE task_new(VALUE Class, VALUE name,VALUE comp_size,VALUE comm_size);
22
23 //Get Computation Size
24 static VALUE task_comp(VALUE Class,VALUE task);
25
26 //Get Name
27 static VALUE task_name(VALUE Class,VALUE task);
28
29 // Execute Task
30 static VALUE task_execute(VALUE Class,VALUE task);
31
32 // Sending Task 
33 static void task_send(VALUE Class,VALUE task,VALUE mailbox);
34
35 // Recieve : return a task
36 static VALUE task_receive(VALUE Class,VALUE mailbox);
37
38 // Recieve Task 2 <<  Not Appreciated 
39 static void task_receive2(VALUE Class,VALUE task,VALUE mailbox);
40
41 // Get Sender
42 static VALUE task_sender(VALUE Class,VALUE task);
43
44 // Get Source
45 static VALUE task_source(VALUE Class,VALUE task);
46
47 //Listen From Alias
48 static VALUE task_listen(VALUE Class,VALUE task,VALUE alias);
49
50 //Listen from Host
51 static VALUE task_listen_host(VALUE Class,VALUE task,VALUE alias,VALUE host);
52
53 // put
54 static void task_put(VALUE Class,VALUE task,VALUE host);
55
56 //get
57 static VALUE task_get(VALUE Class);
58 #endif