Orocos Real-Time Toolkit  2.5.0
OperationInterface.idl
00001 #ifndef ORO_CORBA_OPERATION_REPOSITORY_IDL
00002 #define ORO_CORBA_OPERATION_REPOSITORY_IDL
00003 
00004 #ifdef CORBA_IS_TAO
00005 //resolves LNK2005
00006 #include <tao/orb.idl>
00007 #endif
00008 
00009 module RTT
00010 {
00011   module corba
00012   {
00013       typedef sequence<any> CAnyArguments;
00014 
00020     struct CArgumentDescription
00021     {
00022       string name;        
00023       string description; 
00024       string type;        
00025     };
00026 
00027     typedef sequence<CArgumentDescription> CDescriptions;
00028     
00032     exception CWrongArgumentException
00033     {
00034       long which_arg;
00035       long max_arg;
00036     };
00037 
00041     exception CWrongNumbArgException
00042     {
00043       long wanted;
00044       long received;
00045     };
00046 
00050     exception CWrongTypeArgException
00051     {
00052       long whicharg;
00053       string expected;
00054       string received;
00055     };
00056 
00060     exception CNoSuchNameException
00061     {
00062       string name;
00063     };
00064     
00065     enum CSendStatus { CSendFailure, CSendNotReady, CSendSuccess };
00066 
00071     exception CCallInterrupted
00072     {
00073     };
00074     
00081     interface CSendHandle {
00082     
00083         CSendStatus collect(out CAnyArguments args);
00084 
00085         CSendStatus collectIfDone(out CAnyArguments args);
00086         
00090         CSendStatus checkStatus();
00095         any ret();                       
00096 
00105       void checkArguments(in CAnyArguments args) raises (
00106                                  CWrongNumbArgException,
00107                                  CWrongTypeArgException);
00108 
00114       void dispose();
00115     };
00116 
00121     interface COperationInterface
00122     {
00123     typedef sequence<string> COperationList;
00124 
00128       COperationList getOperations();
00129 
00133       CDescriptions getArguments(in string operation) raises (CNoSuchNameException);
00134 
00139       unsigned short getArity(in string operation) raises (CNoSuchNameException);
00140 
00145       unsigned short getCollectArity(in string operation) raises (CNoSuchNameException);
00146 
00150       string getResultType(in string operation) raises (CNoSuchNameException);
00151       
00155       string getArgumentType(in string operation, in unsigned short nbr) raises (CNoSuchNameException, CWrongArgumentException);
00156       
00160       string getCollectType(in string operation, in unsigned short nbr) raises (CNoSuchNameException, CWrongArgumentException);
00161 
00165       string getDescription(in string operation) raises (CNoSuchNameException);
00166 
00171       void checkOperation(in string operation, in CAnyArguments args) raises ( CNoSuchNameException,
00172                                  CWrongNumbArgException,
00173                                  CWrongTypeArgException);
00174 
00179       any callOperation(in string operation, inout CAnyArguments args) raises ( CNoSuchNameException,
00180                                  CWrongNumbArgException,
00181                                  CWrongTypeArgException,
00182                                  CCallInterrupted);
00183 
00188       CSendHandle sendOperation(in string operation, in CAnyArguments args) raises ( CNoSuchNameException,
00189                                  CWrongNumbArgException,
00190                                  CWrongTypeArgException,
00191                                  CCallInterrupted);
00192     };
00193 
00194   };
00195 };
00196 #endif