PaCO++
0.05
|
00001 // Written by André Ribes 2002 00002 00003 #ifndef __PaCO_idl__ 00004 #define __PaCO_idl__ 00005 00006 // This file contains all the definitions idl for PaCO++ 00007 00008 module PaCO 00009 { 00011 // Distribution Structures 00012 enum distLoc_t { none, ClientSide, ServerSide, CommSide }; 00013 00014 // Description of all the data 00015 typedef struct PacoGlobalData_s 00016 { 00017 unsigned long len; 00018 unsigned long unit_size; 00019 unsigned long cyclic; // how it is distributed : 0:BLOCK, 1:CYCLIC(1), n>=2:CYCLIC(n) 00020 } PacoGlobalData_t; 00021 00022 // Description of a particular data 00023 // a native type is needed for a pointer to data 00024 typedef struct PacoLocalData_s 00025 { 00026 unsigned long rank; 00027 unsigned long start; // global offset 00028 unsigned long len; // number of element 00029 // a native type is needed for a pointer to data 00030 } PacoLocalData_t; 00031 00032 // PaCO object Topology 00033 typedef struct PacoTopology_s 00034 { 00035 unsigned long total; 00036 } PacoTopology_t; 00037 00038 // Permits to init the bib 00039 typedef struct PacoInitData_s 00040 { 00041 PacoGlobalData_t gd; 00042 PacoLocalData_t ld; 00043 } PacoInitData_t; 00044 00045 typedef sequence<PacoLocalData_t> seqLocalData_t; 00046 00047 typedef struct DistributedData_s 00048 { 00049 PacoTopology_t topo; /* dest ou source */ 00050 PacoGlobalData_t gd; 00051 seqLocalData_t dist; /* dest ou source */ 00052 distLoc_t mode; /* library mode */ 00053 } DistributedData_t; 00054 00055 // Connection informations 00056 struct ConnectionInfos 00057 { 00058 // version simple a refaire 00059 sequence<string> nodes; 00060 short request_uid; 00061 PacoTopology_t serveur_topo; 00062 }; 00063 00065 // Interfaces 00066 interface ParallelKernel 00067 { 00068 // For clients stubs to call the InterfaceManager 00069 // Get connection informations 00070 ConnectionInfos getConnectionInfos(); 00071 }; 00072 00073 // A PaCO++ interface parallel or object node parallel 00074 interface InterfaceParallel : ParallelKernel 00075 { 00076 // For the servant 00077 00078 // Get the logical Rank 00079 short getMyRank(); 00080 // Get the total Number of nodes 00081 short getTotalNode(); 00082 // Get the deploy Rank 00083 short getDeployRank(); 00084 00085 // The InterfaceManager call this method to initialize the InterfaceParallel 00086 void init_InterfaceParallel(in short myRank, in short totalNode, in PacoTopology_t topo); 00087 //void init_InterfaceParallel(in short totalNode); 00088 // To inform the interface manager 00089 void deploy(in short rank); 00090 00091 // Return interface manager 00092 void refReturnObject(in string ref); 00093 void connect_return_object(in short client_id); 00094 00095 // FOR EXCEPTION HANDLING 00096 // NOT COMPLETELY IMPLEMENTED 00097 typedef sequence<string> ref; 00098 void setRef(in ref ref_nodes); 00099 void addException(in short except); 00100 }; 00101 00102 // The interface manager 00103 interface InterfaceManager : ParallelKernel 00104 { 00105 // Initialize the InterfaceManager 00106 // void setConnectionInfos(in ConnectionInfos infos); // deprecated 00107 void setTotalNode(in short totalNode); 00108 void setTopo(in PacoTopology_t topo); 00109 //short getTotalNode(); 00110 void setNewNode(in string node, in short rank); 00111 void setWorkNode(in short totalNode); 00112 void setReturn(in string ref); 00113 string getReturn(); 00114 void return_ok(in short client_id); 00115 short getClientId(); 00116 }; 00117 }; 00118 00119 #endif